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.

Issues (389)

Branch: master

src/Widgets/Messages/Messages.php (1 issue)

Labels
Severity
1
<?php
2
3
namespace SleepingOwl\Admin\Widgets\Messages;
4
5
use AdminTemplate;
0 ignored issues
show
The type AdminTemplate was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
6
use SleepingOwl\Admin\Widgets\Widget;
7
8
abstract class Messages extends Widget
9
{
10
    /**
11
     * @var string
12
     */
13
    protected static $sessionName;
14
15
    /**
16
     * @var string
17
     */
18
    protected $messageView;
19
20
    /**
21
     * Get content as a string of HTML.
22
     *
23
     * @return string
24
     */
25
    public function toHtml()
26
    {
27
        return AdminTemplate::view($this->messageView, [
28
            'messages' => $this->getMessage(),
29
        ])->render();
30
    }
31
32
    /**
33
     * @return string|array
34
     */
35 285
    public function template()
36
    {
37 285
        return AdminTemplate::getViewPath('_layout.inner');
38
    }
39
40
    /**
41
     * @return string
42
     */
43
    public function block()
44
    {
45
        return 'content.top';
46
    }
47
48
    /**
49
     * @return string
50
     */
51
    public function getMessageView()
52
    {
53
        return $this->messageView;
54
    }
55
56
    /**
57
     * @param string $messageView
58
     */
59
    public function setMessageView($messageView)
60
    {
61
        $this->messageView = $messageView;
62
    }
63
64
    /**
65
     * @return mixed
66
     */
67
    protected function getMessage()
68
    {
69
        return session(static::$sessionName);
70
    }
71
72
    /**
73
     * @param string $text
74
     * @return mixed
75
     */
76
    public static function addMessage($text)
77
    {
78
        return session()->flash(static::$sessionName, $text);
79
    }
80
}
81