Passed
Push — master ( b4e250...ccc78f )
by Craig
02:55
created

WordFinder   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 10
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 3
c 1
b 0
f 0
dl 0
loc 10
rs 10
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A getFacadeAccessor() 0 3 1
A getRandomChar() 0 3 1
1
<?php
2
3
namespace CustomD\WordFinder\Facades;
4
5
use Illuminate\Support\Facades\Facade;
6
7
/**
8
* @method static \CustomD\WordFinder\Grid create(Collection $wordList, ?int $gridSize = null, ?int $min_word_length = null, ?int $max_word_length = null)
9
*
10
* @see \CustomD\WordFinder\WordFinder
11
*/
12
class WordFinder extends Facade
13
{
14
    protected static function getFacadeAccessor()
15
    {
16
        return 'word-finder';
17
    }
18
19
    public static function getRandomChar(): string
20
    {
21
        return resolve(config('word-finder.character_map'))->getRandomChar();
0 ignored issues
show
Bug introduced by
The method getRandomChar() does not exist on Illuminate\Contracts\Foundation\Application. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-call  annotation

21
        return resolve(config('word-finder.character_map'))->/** @scrutinizer ignore-call */ getRandomChar();

This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.

This is most likely a typographical error or the method has been renamed.

Loading history...
22
    }
23
}
24