Skip to content

Commit

Permalink
fix table schema deprecation
Browse files Browse the repository at this point in the history
  • Loading branch information
skie committed Jan 17, 2024
1 parent 9dd4e05 commit f92ab2c
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/Model/Table/AuthStoreTable.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,16 +63,17 @@ public function validationDefault(Validator $validator): Validator
}



/**
* Field additional_data is json
* Initialize schema
*
* @param \Cake\Database\Schema\TableSchemaInterface $schema The table definition fetched from database.
* @return \Cake\Database\Schema\TableSchemaInterface the altered schema
* @return \Cake\Database\Schema\TableSchemaInterface
*/
protected function _initializeSchema(TableSchemaInterface $schema): TableSchemaInterface
public function getSchema(): TableSchemaInterface
{
$schema = parent::getSchema();
$schema->setColumnType('store', 'json');

return parent::_initializeSchema($schema);
return $schema;
}
}

0 comments on commit f92ab2c

Please sign in to comment.