Use zstd for domain home pages info, added nunomaduro/laravel-console-summary

This commit is contained in:
Deon George
2022-10-23 20:11:03 +11:00
parent 5745c67538
commit e6ba03080b
5 changed files with 1331 additions and 1861 deletions

View File

@@ -46,14 +46,15 @@ class Domain extends Model
/* ATTRIBUTES */
public function getHomePageAttribute($value)
public function getHomePageAttribute(string $value): string
{
return $value ? gzuncompress(base64_decode($value)) : 'No available information at the moment.';
//0xFD2FB528
return $value ? zstd_uncompress(base64_decode($value)) : 'No available information at the moment.';
}
public function setHomePageAttribute($value)
public function setHomePageAttribute(string $value): void
{
$this->attributes['homepage'] = base64_encode(gzcompress($value,9));
$this->attributes['homepage'] = base64_encode(zstd_compress($value,9));
}
/* METHODS */