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.

Code Duplication    Length = 28-28 lines in 3 locations

symphony/content/content.blueprintsdatasources.php 1 location

@@ 38-65 (lines=28) @@
35
    {
36
        $formHasErrors = (is_array($this->_errors) && !empty($this->_errors));
37
38
        if ($formHasErrors) {
39
            $this->pageAlert(
40
                __('An error occurred while processing this form. See below for details.'),
41
                Alert::ERROR
42
            );
43
44
            // These alerts are only valid if the form doesn't have errors
45
        } elseif (isset($this->_context['flag'])) {
46
            $time = Widget::Time();
47
48
            switch ($this->_context['flag']) {
49
                case 'saved':
50
                    $message = __('Data Source updated at %s.', array($time->generate()));
51
                    break;
52
                case 'created':
53
                    $message = __('Data Source created at %s.', array($time->generate()));
54
            }
55
56
            $this->pageAlert(
57
                $message
58
                . ' <a href="' . SYMPHONY_URL . '/blueprints/datasources/new/" accesskey="c">'
59
                . __('Create another?')
60
                . '</a> <a href="' . SYMPHONY_URL . '/blueprints/datasources/" accesskey="a">'
61
                . __('View all Data Sources')
62
                . '</a>',
63
                Alert::SUCCESS
64
            );
65
        }
66
67
        $providers = Symphony::ExtensionManager()->getProvidersOf(iProvider::DATASOURCE);
68
        $isEditing = $this->_context['action'] === 'edit';

symphony/content/content.blueprintsevents.php 1 location

@@ 42-69 (lines=28) @@
39
    {
40
        $formHasErrors = (is_array($this->_errors) && !empty($this->_errors));
41
42
        if ($formHasErrors) {
43
            $this->pageAlert(
44
                __('An error occurred while processing this form. See below for details.'),
45
                Alert::ERROR
46
            );
47
48
            // These alerts are only valid if the form doesn't have errors
49
        } elseif (isset($this->_context['flag'])) {
50
            $time = Widget::Time();
51
52
            switch ($this->_context['flag']) {
53
                case 'saved':
54
                    $message = __('Event updated at %s.', array($time->generate()));
55
                    break;
56
                case 'created':
57
                    $message = __('Event created at %s.', array($time->generate()));
58
            }
59
60
            $this->pageAlert(
61
                $message
62
                . ' <a href="' . SYMPHONY_URL . '/blueprints/events/new/" accesskey="c">'
63
                . __('Create another?')
64
                . '</a> <a href="' . SYMPHONY_URL . '/blueprints/events/" accesskey="a">'
65
                . __('View all Events')
66
                . '</a>',
67
                Alert::SUCCESS
68
            );
69
        }
70
71
        $isEditing = ($readonly ? true : false);
72
        $fields = array("name"=>null, "filters"=>null);

symphony/content/content.blueprintssections.php 1 location

@@ 353-380 (lines=28) @@
350
351
        $formHasErrors = (is_array($this->_errors) && !empty($this->_errors));
352
353
        if ($formHasErrors) {
354
            $this->pageAlert(
355
                __('An error occurred while processing this form. See below for details.'),
356
                Alert::ERROR
357
            );
358
359
            // These alerts are only valid if the form doesn't have errors
360
        } elseif (isset($this->_context['flag'])) {
361
            $time = Widget::Time();
362
363
            switch ($this->_context['flag']) {
364
                case 'saved':
365
                    $message = __('Section updated at %s.', array($time->generate()));
366
                    break;
367
                case 'created':
368
                    $message = __('Section created at %s.', array($time->generate()));
369
            }
370
371
            $this->pageAlert(
372
                $message
373
                . ' <a href="' . SYMPHONY_URL . '/blueprints/sections/new/" accesskey="c">'
374
                . __('Create another?')
375
                . '</a> <a href="' . SYMPHONY_URL . '/blueprints/sections/" accesskey="a">'
376
                . __('View all Sections')
377
                . '</a>',
378
                Alert::SUCCESS
379
            );
380
        }
381
382
        if (isset($_POST['fields'])) {
383
            $fields = array();