Completed
Push — master ( 393727...543190 )
by Vincenzo
03:00
created
api/database/migrations/CreateTeamTable.php 1 patch
Indentation   +15 added lines, -15 removed lines patch added patch discarded remove patch
@@ -5,19 +5,19 @@
 block discarded – undo
5 5
 
6 6
 class CreateTeamTable
7 7
 {
8
-    /**
9
-     * Run the migrations.
10
-     *
11
-     * @return void
12
-     */
13
-    public function run()
14
-    {
15
-        Capsule::schema()->dropIfExists('teams');
16
-        Capsule::schema()->create('teams', function (Blueprint $table) {
17
-            $table->increments('id');
18
-            $table->string('name');
19
-            $table->string('nationality',2);
20
-            $table->timestamps();
21
-        });
22
-    }
8
+	/**
9
+	 * Run the migrations.
10
+	 *
11
+	 * @return void
12
+	 */
13
+	public function run()
14
+	{
15
+		Capsule::schema()->dropIfExists('teams');
16
+		Capsule::schema()->create('teams', function (Blueprint $table) {
17
+			$table->increments('id');
18
+			$table->string('name');
19
+			$table->string('nationality',2);
20
+			$table->timestamps();
21
+		});
22
+	}
23 23
 }
Please login to merge, or discard this patch.
api/database/migrations/CreateCoachesTable.php 1 patch
Indentation   +30 added lines, -30 removed lines patch added patch discarded remove patch
@@ -5,35 +5,35 @@
 block discarded – undo
5 5
 
6 6
 class CreateCoachesTable
7 7
 {
8
-    /**
9
-     * Run the migrations.
10
-     *
11
-     * @return void
12
-     */
13
-    public function run()
14
-    {
15
-        Capsule::schema()->dropIfExists('coaches');
16
-        Capsule::schema()->create('coaches', function (Blueprint $table) {
17
-            $table->increments('id');
18
-            $table->string('name');
19
-            $table->string('surname');
20
-            $table->tinyInteger('age');
21
-            $table->string('nationality',2);
22
-            $table->float('skillAvg');
23
-            $table->float('wageReq');
24
-            $table->string('favouriteModule',10);
25
-            $table->integer('team_id')->nullable();
26
-            $table->timestamps();
27
-        });
28
-    }
8
+	/**
9
+	 * Run the migrations.
10
+	 *
11
+	 * @return void
12
+	 */
13
+	public function run()
14
+	{
15
+		Capsule::schema()->dropIfExists('coaches');
16
+		Capsule::schema()->create('coaches', function (Blueprint $table) {
17
+			$table->increments('id');
18
+			$table->string('name');
19
+			$table->string('surname');
20
+			$table->tinyInteger('age');
21
+			$table->string('nationality',2);
22
+			$table->float('skillAvg');
23
+			$table->float('wageReq');
24
+			$table->string('favouriteModule',10);
25
+			$table->integer('team_id')->nullable();
26
+			$table->timestamps();
27
+		});
28
+	}
29 29
 
30
-    /**
31
-     * Reverse the migrations.
32
-     *
33
-     * @return void
34
-     */
35
-    public function down()
36
-    {
37
-        Schema::drop('coaches');
38
-    }
30
+	/**
31
+	 * Reverse the migrations.
32
+	 *
33
+	 * @return void
34
+	 */
35
+	public function down()
36
+	{
37
+		Schema::drop('coaches');
38
+	}
39 39
 }
Please login to merge, or discard this patch.
api/database/migrations/CreatePlayersTable.php 1 patch
Indentation   +22 added lines, -22 removed lines patch added patch discarded remove patch
@@ -5,26 +5,26 @@
 block discarded – undo
5 5
 
6 6
 class CreatePlayersTable
7 7
 {
8
-    /**
9
-     * Run the migrations.
10
-     *
11
-     * @return void
12
-     */
13
-    public function run()
14
-    {
15
-        Capsule::schema()->dropIfExists('players');
16
-        Capsule::schema()->create('players', function (Blueprint $table) {
17
-            $table->increments('id');
18
-            $table->string('name');
19
-            $table->string('surname');
20
-            $table->tinyInteger('age');
21
-            $table->string('nationality',2);
22
-            $table->float('skillAvg');
23
-            $table->float('wageReq');
24
-            $table->float('val');
25
-            $table->string('role',2);
26
-            $table->integer('team_id')->nullable();
27
-            $table->timestamps();
28
-        });
29
-    }
8
+	/**
9
+	 * Run the migrations.
10
+	 *
11
+	 * @return void
12
+	 */
13
+	public function run()
14
+	{
15
+		Capsule::schema()->dropIfExists('players');
16
+		Capsule::schema()->create('players', function (Blueprint $table) {
17
+			$table->increments('id');
18
+			$table->string('name');
19
+			$table->string('surname');
20
+			$table->tinyInteger('age');
21
+			$table->string('nationality',2);
22
+			$table->float('skillAvg');
23
+			$table->float('wageReq');
24
+			$table->float('val');
25
+			$table->string('role',2);
26
+			$table->integer('team_id')->nullable();
27
+			$table->timestamps();
28
+		});
29
+	}
30 30
 }
Please login to merge, or discard this patch.
api/config/config.php 1 patch
Indentation   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -4,9 +4,9 @@  discard block
 block discarded – undo
4 4
 
5 5
 $dotenv = new Dotenv\Dotenv(__DIR__ . "/../");
6 6
 try {
7
-    $dotenv->load();
7
+	$dotenv->load();
8 8
 } catch (Exception $e) {
9
-    //yummy exception
9
+	//yummy exception
10 10
 }
11 11
 
12 12
 /**
@@ -14,14 +14,14 @@  discard block
 block discarded – undo
14 14
  */
15 15
 $capsule = new Capsule;
16 16
 $capsule->addConnection(array(
17
-    'driver' => 'mysql',
18
-    'host' => 'localhost',
19
-    'database' => 'dsmanager',
20
-    'username' => getenv('USERNAME'),
21
-    'password' => getenv('PASSWORD'),
22
-    'charset' => 'utf8',
23
-    'collation' => 'utf8_general_ci',
24
-    'prefix' => ''
17
+	'driver' => 'mysql',
18
+	'host' => 'localhost',
19
+	'database' => 'dsmanager',
20
+	'username' => getenv('USERNAME'),
21
+	'password' => getenv('PASSWORD'),
22
+	'charset' => 'utf8',
23
+	'collation' => 'utf8_general_ci',
24
+	'prefix' => ''
25 25
 ));
26 26
 $capsule->setAsGlobal();
27 27
 $capsule->bootEloquent();
Please login to merge, or discard this patch.
api/database/seeds/BMatchesSeeder.php 1 patch
Indentation   +16 added lines, -16 removed lines patch added patch discarded remove patch
@@ -3,20 +3,20 @@
 block discarded – undo
3 3
 
4 4
 class BMatchesSeeder
5 5
 {
6
-    function run()
7
-    {
8
-        $teams = \App\Lib\DsManager\Models\Orm\Team::all()->toArray();
9
-        $halfTheTeams = count($teams) / 2;
10
-        $chunks = array_chunk($teams, $halfTheTeams);
11
-        $teamsSlice1 = $chunks[0];
12
-        $teamsSlice2 = $chunks[1];
13
-        for ($i = 0; $i < $halfTheTeams; $i++) {
14
-            \App\Lib\DsManager\Models\Orm\Match::create(
15
-                [
16
-                    'home_team_id' => $teamsSlice1[$i]['id'],
17
-                    'away_team_id' => $teamsSlice2[$i]['id']
18
-                ]
19
-            );
20
-        }
21
-    }
6
+	function run()
7
+	{
8
+		$teams = \App\Lib\DsManager\Models\Orm\Team::all()->toArray();
9
+		$halfTheTeams = count($teams) / 2;
10
+		$chunks = array_chunk($teams, $halfTheTeams);
11
+		$teamsSlice1 = $chunks[0];
12
+		$teamsSlice2 = $chunks[1];
13
+		for ($i = 0; $i < $halfTheTeams; $i++) {
14
+			\App\Lib\DsManager\Models\Orm\Match::create(
15
+				[
16
+					'home_team_id' => $teamsSlice1[$i]['id'],
17
+					'away_team_id' => $teamsSlice2[$i]['id']
18
+				]
19
+			);
20
+		}
21
+	}
22 22
 }
23 23
\ No newline at end of file
Please login to merge, or discard this patch.
api/database/migrations/CreateMatchTable.php 1 patch
Indentation   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -5,24 +5,24 @@
 block discarded – undo
5 5
 
6 6
 class CreateMatchTable
7 7
 {
8
-    /**
9
-     * Run the migrations.
10
-     *
11
-     * @return void
12
-     */
13
-    public function run()
14
-    {
15
-        Capsule::schema()->dropIfExists('matches');
16
-        Capsule::schema()->create('matches', function (Blueprint $table) {
17
-            $table->increments('id');
18
-            $table->integer('home_team_id');
19
-            $table->integer('goal_home')->default(0);
20
-            $table->integer('away_team_id');
21
-            $table->integer('goal_away')->default(0);
22
-            $table->boolean('simulated')->default(false);
23
-            $table->text('info')->nullable();
24
-            $table->date('match_date')->default(\Carbon\Carbon::now());
25
-            $table->timestamps();
26
-        });
27
-    }
8
+	/**
9
+	 * Run the migrations.
10
+	 *
11
+	 * @return void
12
+	 */
13
+	public function run()
14
+	{
15
+		Capsule::schema()->dropIfExists('matches');
16
+		Capsule::schema()->create('matches', function (Blueprint $table) {
17
+			$table->increments('id');
18
+			$table->integer('home_team_id');
19
+			$table->integer('goal_home')->default(0);
20
+			$table->integer('away_team_id');
21
+			$table->integer('goal_away')->default(0);
22
+			$table->boolean('simulated')->default(false);
23
+			$table->text('info')->nullable();
24
+			$table->date('match_date')->default(\Carbon\Carbon::now());
25
+			$table->timestamps();
26
+		});
27
+	}
28 28
 }
Please login to merge, or discard this patch.
api/Lib/DsManager/Models/Match.php 1 patch
Indentation   +160 added lines, -160 removed lines patch added patch discarded remove patch
@@ -11,164 +11,164 @@
 block discarded – undo
11 11
  */
12 12
 class Match extends DsManagerModel
13 13
 {
14
-    /**
15
-     * @var Team
16
-     */
17
-    private $homeTeam;
18
-    /**
19
-     * @var Team
20
-     */
21
-    private $awayTeam;
22
-
23
-    /**
24
-     * Match constructor.
25
-     * @param Team $home
26
-     * @param Team $away
27
-     */
28
-    public function __construct(Team $home, Team $away)
29
-    {
30
-        $this->homeTeam = $home;
31
-        $this->awayTeam = $away;
32
-    }
33
-
34
-    /**
35
-     * @return MatchResult
36
-     */
37
-    public function simulate()
38
-    {
39
-        $homePoints = $this->homeTeam->getAvgSkill();
40
-        $awayPoints = $this->awayTeam->getAvgSkill();
41
-
42
-        $homePoints += $this->malusModule(
43
-            $this->homeTeam->coach->favouriteModule,
44
-            $this->homeTeam->playersPerRoleArray()
45
-        );
46
-        $awayPoints += $this->malusModule(
47
-            $this->awayTeam->coach->favouriteModule,
48
-            $this->awayTeam->playersPerRoleArray()
49
-        );
50
-
51
-        $goalHome = 0;
52
-        $goalAway = 0;
53
-
54
-        if (Randomizer::boolOnPercentage(80)) {
55
-            if (($homePoints - $awayPoints) < 0) {
56
-                $goalAway = ($awayPoints - $homePoints) % 6;
57
-                $goalHome += $this->chance();
58
-                $goalAway += $this->chance();
59
-                $goalHome += $this->bonusHome();
60
-            } else {
61
-                $goalHome = ($homePoints - $awayPoints) % 6;
62
-                $goalAway += $this->chance();
63
-                $goalHome += $this->bonusHome();
64
-            }
65
-        } else {
66
-            $goalHome += $this->chance();
67
-            $goalAway += $this->chance();
68
-            $goalHome += $this->bonusHome();
69
-        }
70
-        $goalHome += $this->bonusAge($this->homeTeam);
71
-        $goalAway += $this->bonusAge($this->awayTeam);
72
-
73
-        //Bonus on Good GoalKeeper
74
-        $goalies = $this->homeTeam->getBestPlayerForRole("GK");
75
-        $goalAway -= $this->bonusGoalKeeper($goalies);
76
-        $goalies = $this->awayTeam->getBestPlayerForRole("GK");
77
-        $goalHome -= $this->bonusGoalKeeper($goalies);
78
-        //
79
-        $homeModule = new Module($this->homeTeam->coach->favouriteModule);
80
-        $awayModule = new Module($this->awayTeam->coach->favouriteModule);
81
-        if ($homeModule->isOffensive()) {
82
-            $goalHome += Randomizer::boolOnPercentage(50) ? rand(1, 2) : 0;
83
-            $goalAway += Randomizer::boolOnPercentage(20) ? 1 : 0;
84
-        }
85
-        if ($awayModule->isOffensive()) {
86
-            $goalAway += Randomizer::boolOnPercentage(50) ? rand(1, 2) : 0;
87
-            $goalHome += Randomizer::boolOnPercentage(20) ? 1 : 0;
88
-        }
89
-        if ($awayModule->isDefensive()) {
90
-            $goalHome -= Randomizer::boolOnPercentage(50) ? 1 : 0;
91
-        }
92
-        if ($homeModule->isDefensive()) {
93
-            $goalAway -= Randomizer::boolOnPercentage(50) ? 1 : 0;
94
-        }
95
-        $goalHome = $goalHome < 0 ? 0 : $goalHome;
96
-        $goalAway = $goalAway < 0 ? 0 : $goalAway;
97
-        return new MatchResult($goalHome, $goalAway, $this->homeTeam, $this->awayTeam);
98
-    }
99
-
100
-    /**
101
-     * @param Team $team
102
-     * @return int
103
-     */
104
-    private function bonusAge(Team $team)
105
-    {
106
-        if ($team->getAvgAge() > 29 || $team->getAvgAge() < 24) {
107
-            return $this->chance();
108
-        }
109
-        return 0;
110
-    }
111
-
112
-    /**
113
-     * @param $goalkeeper
114
-     * @return int
115
-     */
116
-    private function bonusGoalKeeper($goalkeeper)
117
-    {
118
-        $skillGoalkeeper = empty($goalkeeper) ? 1 : $goalkeeper->skillAvg;
119
-        return (Randomizer::boolOnPercentage($skillGoalkeeper) ? 1 : 0);
120
-    }
121
-
122
-    /**
123
-     * @return int
124
-     */
125
-    private function chance()
126
-    {
127
-        return rand(0, 3);
128
-    }
129
-
130
-    /**
131
-     * @return int
132
-     */
133
-    private function bonusHome()
134
-    {
135
-        return Randomizer::boolOnPercentage(66) ? 1 : 0;
136
-    }
137
-
138
-    /**
139
-     * @param $moduleString
140
-     * @param $playersRoleArray
141
-     * @return int
142
-     */
143
-    private function malusModule($moduleString, $playersRoleArray)
144
-    {
145
-        $module = new Module($moduleString);
146
-        if ($module->isApplicableToArray($playersRoleArray)) {
147
-            return rand(1, 10);
148
-        } else {
149
-            return (-1) * rand(1, 10);
150
-        }
151
-    }
152
-
153
-    /**
154
-     * @param array $ormMatchArray
155
-     * @return Match
156
-     */
157
-    public static function fromArray($ormMatchArray = [])
158
-    {
159
-        $homeTeam = Team::fromArray($ormMatchArray['home_team']);
160
-        $awayTeam = Team::fromArray($ormMatchArray['away_team']);
161
-        return new Match($homeTeam, $awayTeam);
162
-    }
163
-
164
-    /**
165
-     * @return mixed
166
-     */
167
-    function toArray()
168
-    {
169
-        $result = [];
170
-        $result['home_team_id'] = $this->homeTeam->id;
171
-        $result['away_team_id'] = $this->awayTeam->id;
172
-        return $result;
173
-    }
14
+	/**
15
+	 * @var Team
16
+	 */
17
+	private $homeTeam;
18
+	/**
19
+	 * @var Team
20
+	 */
21
+	private $awayTeam;
22
+
23
+	/**
24
+	 * Match constructor.
25
+	 * @param Team $home
26
+	 * @param Team $away
27
+	 */
28
+	public function __construct(Team $home, Team $away)
29
+	{
30
+		$this->homeTeam = $home;
31
+		$this->awayTeam = $away;
32
+	}
33
+
34
+	/**
35
+	 * @return MatchResult
36
+	 */
37
+	public function simulate()
38
+	{
39
+		$homePoints = $this->homeTeam->getAvgSkill();
40
+		$awayPoints = $this->awayTeam->getAvgSkill();
41
+
42
+		$homePoints += $this->malusModule(
43
+			$this->homeTeam->coach->favouriteModule,
44
+			$this->homeTeam->playersPerRoleArray()
45
+		);
46
+		$awayPoints += $this->malusModule(
47
+			$this->awayTeam->coach->favouriteModule,
48
+			$this->awayTeam->playersPerRoleArray()
49
+		);
50
+
51
+		$goalHome = 0;
52
+		$goalAway = 0;
53
+
54
+		if (Randomizer::boolOnPercentage(80)) {
55
+			if (($homePoints - $awayPoints) < 0) {
56
+				$goalAway = ($awayPoints - $homePoints) % 6;
57
+				$goalHome += $this->chance();
58
+				$goalAway += $this->chance();
59
+				$goalHome += $this->bonusHome();
60
+			} else {
61
+				$goalHome = ($homePoints - $awayPoints) % 6;
62
+				$goalAway += $this->chance();
63
+				$goalHome += $this->bonusHome();
64
+			}
65
+		} else {
66
+			$goalHome += $this->chance();
67
+			$goalAway += $this->chance();
68
+			$goalHome += $this->bonusHome();
69
+		}
70
+		$goalHome += $this->bonusAge($this->homeTeam);
71
+		$goalAway += $this->bonusAge($this->awayTeam);
72
+
73
+		//Bonus on Good GoalKeeper
74
+		$goalies = $this->homeTeam->getBestPlayerForRole("GK");
75
+		$goalAway -= $this->bonusGoalKeeper($goalies);
76
+		$goalies = $this->awayTeam->getBestPlayerForRole("GK");
77
+		$goalHome -= $this->bonusGoalKeeper($goalies);
78
+		//
79
+		$homeModule = new Module($this->homeTeam->coach->favouriteModule);
80
+		$awayModule = new Module($this->awayTeam->coach->favouriteModule);
81
+		if ($homeModule->isOffensive()) {
82
+			$goalHome += Randomizer::boolOnPercentage(50) ? rand(1, 2) : 0;
83
+			$goalAway += Randomizer::boolOnPercentage(20) ? 1 : 0;
84
+		}
85
+		if ($awayModule->isOffensive()) {
86
+			$goalAway += Randomizer::boolOnPercentage(50) ? rand(1, 2) : 0;
87
+			$goalHome += Randomizer::boolOnPercentage(20) ? 1 : 0;
88
+		}
89
+		if ($awayModule->isDefensive()) {
90
+			$goalHome -= Randomizer::boolOnPercentage(50) ? 1 : 0;
91
+		}
92
+		if ($homeModule->isDefensive()) {
93
+			$goalAway -= Randomizer::boolOnPercentage(50) ? 1 : 0;
94
+		}
95
+		$goalHome = $goalHome < 0 ? 0 : $goalHome;
96
+		$goalAway = $goalAway < 0 ? 0 : $goalAway;
97
+		return new MatchResult($goalHome, $goalAway, $this->homeTeam, $this->awayTeam);
98
+	}
99
+
100
+	/**
101
+	 * @param Team $team
102
+	 * @return int
103
+	 */
104
+	private function bonusAge(Team $team)
105
+	{
106
+		if ($team->getAvgAge() > 29 || $team->getAvgAge() < 24) {
107
+			return $this->chance();
108
+		}
109
+		return 0;
110
+	}
111
+
112
+	/**
113
+	 * @param $goalkeeper
114
+	 * @return int
115
+	 */
116
+	private function bonusGoalKeeper($goalkeeper)
117
+	{
118
+		$skillGoalkeeper = empty($goalkeeper) ? 1 : $goalkeeper->skillAvg;
119
+		return (Randomizer::boolOnPercentage($skillGoalkeeper) ? 1 : 0);
120
+	}
121
+
122
+	/**
123
+	 * @return int
124
+	 */
125
+	private function chance()
126
+	{
127
+		return rand(0, 3);
128
+	}
129
+
130
+	/**
131
+	 * @return int
132
+	 */
133
+	private function bonusHome()
134
+	{
135
+		return Randomizer::boolOnPercentage(66) ? 1 : 0;
136
+	}
137
+
138
+	/**
139
+	 * @param $moduleString
140
+	 * @param $playersRoleArray
141
+	 * @return int
142
+	 */
143
+	private function malusModule($moduleString, $playersRoleArray)
144
+	{
145
+		$module = new Module($moduleString);
146
+		if ($module->isApplicableToArray($playersRoleArray)) {
147
+			return rand(1, 10);
148
+		} else {
149
+			return (-1) * rand(1, 10);
150
+		}
151
+	}
152
+
153
+	/**
154
+	 * @param array $ormMatchArray
155
+	 * @return Match
156
+	 */
157
+	public static function fromArray($ormMatchArray = [])
158
+	{
159
+		$homeTeam = Team::fromArray($ormMatchArray['home_team']);
160
+		$awayTeam = Team::fromArray($ormMatchArray['away_team']);
161
+		return new Match($homeTeam, $awayTeam);
162
+	}
163
+
164
+	/**
165
+	 * @return mixed
166
+	 */
167
+	function toArray()
168
+	{
169
+		$result = [];
170
+		$result['home_team_id'] = $this->homeTeam->id;
171
+		$result['away_team_id'] = $this->awayTeam->id;
172
+		return $result;
173
+	}
174 174
 }
175 175
\ No newline at end of file
Please login to merge, or discard this patch.
api/Lib/DsManager/Models/Orm/Match.php 1 patch
Indentation   +51 added lines, -51 removed lines patch added patch discarded remove patch
@@ -9,62 +9,62 @@
 block discarded – undo
9 9
 class Match extends DsManagerOrm
10 10
 {
11 11
 
12
-    /**
13
-     * @var string
14
-     */
15
-    protected $table = 'matches';
12
+	/**
13
+	 * @var string
14
+	 */
15
+	protected $table = 'matches';
16 16
 
17
-    /**
18
-     * @var array
19
-     */
20
-    protected $fillable = [
21
-        'home_team_id',
22
-        'away_team_id'
23
-    ];
17
+	/**
18
+	 * @var array
19
+	 */
20
+	protected $fillable = [
21
+		'home_team_id',
22
+		'away_team_id'
23
+	];
24 24
 
25
-    /**
26
-     * @var array
27
-     */
28
-    protected $hidden = [
29
-        'home_team_id',
30
-        'away_team_id',
31
-        'created_at',
32
-        'updated_at',
33
-        'info'
34
-    ];
25
+	/**
26
+	 * @var array
27
+	 */
28
+	protected $hidden = [
29
+		'home_team_id',
30
+		'away_team_id',
31
+		'created_at',
32
+		'updated_at',
33
+		'info'
34
+	];
35 35
 
36
-    /**
37
-     * @var array
38
-     */
39
-    protected $casts = [
40
-        'simulated' => 'boolean'
41
-    ];
36
+	/**
37
+	 * @var array
38
+	 */
39
+	protected $casts = [
40
+		'simulated' => 'boolean'
41
+	];
42 42
 
43
-    /**
44
-     * @return \Illuminate\Database\Eloquent\Relations\BelongsTo
45
-     */
46
-    public function homeTeam()
47
-    {
48
-        return $this->belongsTo(Team::class, 'home_team_id');
49
-    }
43
+	/**
44
+	 * @return \Illuminate\Database\Eloquent\Relations\BelongsTo
45
+	 */
46
+	public function homeTeam()
47
+	{
48
+		return $this->belongsTo(Team::class, 'home_team_id');
49
+	}
50 50
 
51
-    /**
52
-     * @return \Illuminate\Database\Eloquent\Relations\BelongsTo
53
-     */
54
-    public function awayTeam()
55
-    {
56
-        return $this->belongsTo(Team::class, 'away_team_id');
57
-    }
51
+	/**
52
+	 * @return \Illuminate\Database\Eloquent\Relations\BelongsTo
53
+	 */
54
+	public function awayTeam()
55
+	{
56
+		return $this->belongsTo(Team::class, 'away_team_id');
57
+	}
58 58
 
59
-    public function scopeComplete($query){
60
-        return $query->with(
61
-            'homeTeam',
62
-            'homeTeam.roster',
63
-            'homeTeam.coach',
64
-            'awayTeam',
65
-            'awayTeam.roster',
66
-            'awayTeam.coach'
67
-        );
68
-    }
59
+	public function scopeComplete($query){
60
+		return $query->with(
61
+			'homeTeam',
62
+			'homeTeam.roster',
63
+			'homeTeam.coach',
64
+			'awayTeam',
65
+			'awayTeam.roster',
66
+			'awayTeam.coach'
67
+		);
68
+	}
69 69
 
70 70
 }
71 71
\ No newline at end of file
Please login to merge, or discard this patch.
api/config/generic.php 1 patch
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -74,10 +74,10 @@
 block discarded – undo
74 74
 		'ro_MD',
75 75
 		'tr_TR'
76 76
 	],
77
-    'rosters' => [
78
-        'min' => 11,
79
-        'max'  => 18
80
-    ],
77
+	'rosters' => [
78
+		'min' => 11,
79
+		'max'  => 18
80
+	],
81 81
 ];
82 82
 
83 83
 
Please login to merge, or discard this patch.