diff --git a/plugin/buy_courses/database.php b/plugin/buy_courses/database.php index b46dc9ace5..cee19a0626 100644 --- a/plugin/buy_courses/database.php +++ b/plugin/buy_courses/database.php @@ -5,7 +5,7 @@ * Date: 21/05/14 * Time: 12:19 PM */ -$objPlugin = new Buy_CoursesPlugin(); +$objPlugin = Buy_CoursesPlugin::create(); $table = Database::get_main_table(TABLE_BUY_COURSE); $sql = "CREATE TABLE IF NOT EXISTS $table ( @@ -295,7 +295,7 @@ Database::query($sql); $table = Database::get_main_table(TABLE_BUY_COURSE_PAYPAL); $sql = "CREATE TABLE IF NOT EXISTS $table ( id INT unsigned NOT NULL auto_increment PRIMARY KEY, - sandbox VARCHAR(5) NOT NULL DEFAULT 'SI', + sandbox VARCHAR(5) NOT NULL DEFAULT 'YES', username VARCHAR(100) NOT NULL DEFAULT '', password VARCHAR(100) NOT NULL DEFAULT '', signature VARCHAR(100) NOT NULL DEFAULT '')"; diff --git a/plugin/buy_courses/src/buy_course_plugin.class.php b/plugin/buy_courses/src/buy_course_plugin.class.php index 3f60d08714..1d7d87b58f 100644 --- a/plugin/buy_courses/src/buy_course_plugin.class.php +++ b/plugin/buy_courses/src/buy_course_plugin.class.php @@ -18,7 +18,7 @@ class Buy_CoursesPlugin extends Plugin return $result ? $result : $result = new self(); } - public function __construct() + protected function __construct() { parent::__construct('1.0', 'Jose Angel Ruiz, Francis Gonzales', array('paypal_enable' => 'boolean', 'transference_enable' => 'boolean', 'unregistered_users_enable' => 'boolean')); } diff --git a/plugin/ticket/database.php b/plugin/ticket/database.php index 9d3dce07c8..8035f0a651 100644 --- a/plugin/ticket/database.php +++ b/plugin/ticket/database.php @@ -3,7 +3,7 @@ * Contains the SQL for the tickets management plugin database structure */ -$objPlugin = new TicketPlugin(); +$objPlugin = TicketPlugin::create(); $table = Database::get_main_table(TABLE_TICKET_ASSIGNED_LOG); $sql = "CREATE TABLE IF NOT EXISTS ".$table." (