Scrutinizer GitHub App not installed

We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.

Install GitHub App

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.
Passed
Pull Request — master (#686)
by Beatrycze
03:36
created

View3D::main()   A

Complexity

Conditions 3
Paths 3

Size

Total Lines 28
Code Lines 14

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 14
c 1
b 0
f 0
dl 0
loc 28
rs 9.7998
cc 3
nc 3
nop 2
1
<?php
2
3
/**
4
 * (c) Kitodo. Key to digital objects e.V. <[email protected]>
5
 *
6
 * This file is part of the Kitodo and TYPO3 projects.
7
 *
8
 * @license GNU General Public License version 3 or later.
9
 * For the full copyright and license information, please read the
10
 * LICENSE.txt file that was distributed with this source code.
11
 */
12
13
namespace Kitodo\Dlf\Plugin;
14
15
use TYPO3\CMS\Core\Utility\GeneralUtility;
16
17
/**
18
 * Plugin 'Three Dimensional View' for the 'dlf' extension
19
 *
20
 * @author Beatrycze Volk <[email protected]>
21
 * @package TYPO3
22
 * @subpackage dlf
23
 * @access public
24
 */
25
class View3D extends \Kitodo\Dlf\Common\AbstractPlugin
26
{
27
    public $scriptRelPath = 'Classes/Plugin/View3D.php';
28
29
        /**
30
     * The main method of the PlugIn
31
     *
32
     * @access public
33
     *
34
     * @param string $content: The PlugIn content
35
     * @param array $conf: The PlugIn configuration
36
     *
37
     * @return string The content that is displayed on the website
38
     */
39
    public function main($content, $conf)
40
    {
41
        $this->init($conf);
42
        // Load current document.
43
        $this->loadDocument();
44
        // TODO :correct condition for displaying
45
        if (
46
            1 != 1
0 ignored issues
show
introduced by
The condition 1 != 1 is always false.
Loading history...
47
        ) {
48
            // Quit without doing anything if required variables are not set.
49
            return $content;
50
        } else {
51
            // Load template file.
52
            $this->getTemplate();
53
54
            // TODO: read XML with link
55
            $xml = '';
56
            if ($xml !== false) {
0 ignored issues
show
introduced by
The condition $xml !== false is always true.
Loading history...
57
                // Fill in the template markers.
58
                $markerArray = [];
59
                // TODO: URL must be a variable taken from XML
60
                $markerArray['###URL###'] = 'http://localhost:4200/';
61
62
                $content .= $this->templateService->substituteMarkerArray($this->template, $markerArray);
63
                return $this->pi_wrapInBaseClass($content);
64
            }
65
66
            return $content;
67
        }
68
    }
69
}
70