Skip to content

Commit

Permalink
Drop all the deprecated columns in a single statement
Browse files Browse the repository at this point in the history
  • Loading branch information
JoshuaLuckers committed Feb 4, 2023
1 parent b47ba96 commit 9ad5f39
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 26 deletions.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?php

/**
* Scripts removes deprecated fields from the main resource table
*
* @var modX $modx
* @package setup
*/

use MODX\Revolution\modResource;

$class = modResource::class;
$table = $modx->getTableName($class);
$sql = "ALTER TABLE {$modx->escape($table)}
DROP COLUMN `privateweb`,
DROP COLUMN `privatemgr`,
DROP COLUMN `donthit`;";
$modx->exec($sql);
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<?php
/**
* Specific upgrades for Revolution 3.0.2-pl
* Specific upgrades for Revolution 3.1.0-pl
*
* @var modX $modx
* @package setup
* @subpackage upgrades
*/

/* run upgrades common to all db platforms */
include dirname(__DIR__) . '/common/3.0.2-remove-deprecated-resource-fields.php';
include dirname(__DIR__) . '/common/3.1.0-remove-deprecated-resource-fields.php';

0 comments on commit 9ad5f39

Please sign in to comment.