Elgg
Version master
engine
schema
migrations
20200130161435_remove_metadata_columns.php
Go to the documentation of this file.
1
<?php
2
3
use Phinx\Migration\AbstractMigration;
4
5
class
RemoveMetadataColumns
extends
AbstractMigration
6
{
10
public
function
change
() {
11
12
if
($this->hasTable(
'metadata'
)) {
13
$table
= $this->table(
'metadata'
);
14
15
if
(
$table
->hasColumn(
'access_id'
)) {
16
$table
->removeColumn(
'access_id'
);
17
}
18
19
if
(
$table
->hasColumn(
'owner_guid'
)) {
20
$table
->removeColumn(
'owner_guid'
);
21
}
22
23
if
(
$table
->hasColumn(
'enabled'
)) {
24
$table
->removeColumn(
'enabled'
);
25
}
26
27
$table
->save();
28
}
29
}
30
}
$table
$table
Definition:
user.php:37
RemoveMetadataColumns
Definition:
20200130161435_remove_metadata_columns.php:6
RemoveMetadataColumns\change
change()
Removes obsolete columns from metadata table.
Definition:
20200130161435_remove_metadata_columns.php:10
Generated on Wed Aug 13 2025 00:01:44 for Elgg by
1.9.1