From 62dbf81a5b22845a4fcb17a944fec471d796ef50 Mon Sep 17 00:00:00 2001 From: Daniel Supernault Date: Thu, 11 Jul 2019 22:46:32 -0600 Subject: [PATCH] Update Profile model to use snowflake ids --- app/Profile.php | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/app/Profile.php b/app/Profile.php index 0737f9974..d84d708a5 100644 --- a/app/Profile.php +++ b/app/Profile.php @@ -4,12 +4,20 @@ namespace App; use Auth, Cache, Storage; use App\Util\Lexer\PrettyNumber; +use Pixelfed\Snowflake\HasSnowflakePrimary; use Illuminate\Database\Eloquent\{Model, SoftDeletes}; class Profile extends Model { - use SoftDeletes; + use HasSnowflakePrimary, SoftDeletes; + /** + * Indicates if the IDs are auto-incrementing. + * + * @var bool + */ + public $incrementing = false; + protected $dates = ['deleted_at']; protected $hidden = ['private_key']; protected $visible = ['id', 'user_id', 'username', 'name'];