[ENTITY] Remove 'normalized_nickname' field from GSActor as that feature will be moved to a plugin

This commit is contained in:
Hugo Sales 2021-07-28 21:20:32 +00:00
parent 2f69579ddb
commit e77498ac19
Signed by: someonewithpc
GPG Key ID: 7D0C7EAFC9D835A0
1 changed files with 14 additions and 16 deletions

View File

@ -295,25 +295,23 @@ class GSActor extends Entity
'name' => 'gsactor', 'name' => 'gsactor',
'description' => 'local and remote users, groups and bots are gsactors, for instance', 'description' => 'local and remote users, groups and bots are gsactors, for instance',
'fields' => [ 'fields' => [
'id' => ['type' => 'serial', 'not null' => true, 'description' => 'unique identifier'], 'id' => ['type' => 'serial', 'not null' => true, 'description' => 'unique identifier'],
'nickname' => ['type' => 'varchar', 'length' => 64, 'not null' => true, 'description' => 'nickname or username'], 'nickname' => ['type' => 'varchar', 'length' => 64, 'not null' => true, 'description' => 'nickname or username'],
'normalized_nickname' => ['type' => 'varchar', 'length' => 64, 'not null' => true, 'description' => 'normalized (as per Nickanme::normalize) nickname or username'], 'fullname' => ['type' => 'text', 'description' => 'display name'],
'fullname' => ['type' => 'text', 'description' => 'display name'], 'roles' => ['type' => 'int', 'not null' => true, 'default' => UserRoles::USER, 'description' => 'Bitmap of permissions this gsactor has'],
'roles' => ['type' => 'int', 'not null' => true, 'default' => UserRoles::USER, 'description' => 'Bitmap of permissions this gsactor has'], 'homepage' => ['type' => 'text', 'description' => 'identifying URL'],
'homepage' => ['type' => 'text', 'description' => 'identifying URL'], 'bio' => ['type' => 'text', 'description' => 'descriptive biography'],
'bio' => ['type' => 'text', 'description' => 'descriptive biography'], 'location' => ['type' => 'text', 'description' => 'physical location'],
'location' => ['type' => 'text', 'description' => 'physical location'], 'lat' => ['type' => 'numeric', 'precision' => 10, 'scale' => 7, 'description' => 'latitude'],
'lat' => ['type' => 'numeric', 'precision' => 10, 'scale' => 7, 'description' => 'latitude'], 'lon' => ['type' => 'numeric', 'precision' => 10, 'scale' => 7, 'description' => 'longitude'],
'lon' => ['type' => 'numeric', 'precision' => 10, 'scale' => 7, 'description' => 'longitude'], 'location_id' => ['type' => 'int', 'description' => 'location id if possible'],
'location_id' => ['type' => 'int', 'description' => 'location id if possible'], 'location_service' => ['type' => 'int', 'description' => 'service used to obtain location id'],
'location_service' => ['type' => 'int', 'description' => 'service used to obtain location id'], 'created' => ['type' => 'datetime', 'not null' => true, 'default' => 'CURRENT_TIMESTAMP', 'description' => 'date this record was created'],
'created' => ['type' => 'datetime', 'not null' => true, 'default' => 'CURRENT_TIMESTAMP', 'description' => 'date this record was created'], 'modified' => ['type' => 'timestamp', 'not null' => true, 'default' => 'CURRENT_TIMESTAMP', 'description' => 'date this record was modified'],
'modified' => ['type' => 'timestamp', 'not null' => true, 'default' => 'CURRENT_TIMESTAMP', 'description' => 'date this record was modified'],
], ],
'primary key' => ['id'], 'primary key' => ['id'],
'indexes' => [ 'indexes' => [
'gsactor_nickname_idx' => ['nickname'], 'gsactor_nickname_idx' => ['nickname'],
'gsactor_normalized_nickname_idx' => ['normalized_nickname'],
], ],
'fulltext indexes' => [ 'fulltext indexes' => [
'gsactor_fulltext_idx' => ['nickname', 'fullname', 'location', 'bio', 'homepage'], 'gsactor_fulltext_idx' => ['nickname', 'fullname', 'location', 'bio', 'homepage'],