GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Pull Request — integration (#2604)
by Brendan
05:28
created

migration_250   A

Complexity

Total Complexity 5

Size/Duplication

Total Lines 40
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 4

Importance

Changes 0
Metric Value
c 0
b 0
f 0
dl 0
loc 40
rs 10
wmc 5
lcom 0
cbo 4

2 Methods

Rating   Name   Duplication   Size   Complexity  
A getVersion() 0 4 1
A getReleaseNotes() 0 4 1
1
<?php
2
3
namespace SymphonyCms\Installer\Migrations;
4
5
use SymphonyCms\Installer\Lib\Migration;
6
use Symphony;
7
use Exception;
8
9
class migration_250 extends Migration
10
{
11
    public static function getVersion()
12
    {
13
        return '2.5.0';
14
    }
15
16
    public static function getReleaseNotes()
17
    {
18
        return 'http://getsymphony.com/download/releases/version/2.5/';
19
    }
20
21
    public static function upgrade()
22
    {
23
        // Add association interfaces
24
        try {
25
            Symphony::Database()->query('
26
                ALTER TABLE `tbl_sections_association`
27
                ADD `interface` VARCHAR(100) COLLATE utf8_unicode_ci DEFAULT NULL,
28
                ADD `editor` VARCHAR(100) COLLATE utf8_unicode_ci DEFAULT NULL;
29
            ');
30
        } catch (Exception $ex) {
31
        }
32
33
        // Remove show_association #2082
34
        try {
35
            Symphony::Database()->query('
36
                ALTER TABLE `tbl_fields_select` DROP COLUMN show_association;
37
            ');
38
        } catch (Exception $ex) {
39
        }
40
41
        // Remove XSRF configuration options #2118
42
        Symphony::Configuration()->remove('token_lifetime', 'symphony');
43
        Symphony::Configuration()->remove('invalidate_tokens_on_request', 'symphony');
44
45
        // Update the version information
46
        return parent::upgrade();
47
    }
48
}
49