Passed
Push — develop ( 4a5a66...90be87 )
by BENARD
04:36
created

GameMethodsTrait::getGame()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 1
dl 0
loc 3
c 0
b 0
f 0
rs 10
cc 1
nc 1
nop 0
1
<?php
2
3
declare(strict_types=1);
4
5
namespace VideoGamesRecords\CoreBundle\Traits\Entity\Game;
6
7
use VideoGamesRecords\CoreBundle\Entity\Game;
8
9
trait GameMethodsTrait
10
{
11
    /**
12
     * @param Game $game
13
     * @return $this
14
     */
15
    public function setGame(Game $game): static
16
    {
17
        $this->game = $game;
0 ignored issues
show
Bug Best Practice introduced by
The property game does not exist. Although not strictly required by PHP, it is generally a best practice to declare properties explicitly.
Loading history...
18
        return $this;
19
    }
20
21
    /**
22
     * Get game
23
     *
24
     * @return Game
25
     */
26
    public function getGame(): Game
27
    {
28
        return $this->game;
29
    }
30
}
31