Elgg  Version 6.2
20240318105727_remove_annotations_enabled_column.php
Go to the documentation of this file.
1 <?php
2 declare(strict_types=1);
3 
4 use Phinx\Migration\AbstractMigration;
5 
6 class RemoveAnnotationsEnabledColumn extends AbstractMigration {
10  public function change(): void {
11 
12  if ($this->hasTable('annotations')) {
13  $table = $this->table('annotations');
14 
15  if ($table->hasColumn('enabled')) {
16  $table->removeColumn('enabled');
17  }
18 
19  $table->save();
20  }
21  }
22 }
$table
Definition: user.php:37
if(parse_url(elgg_get_site_url(), PHP_URL_PATH) !=='/') if(file_exists(elgg_get_root_path() . 'robots.txt'))
Set robots.txt.
Definition: robots.php:10