Completed
Push — master ( 5bc292...02102e )
by Michael
03:27
created
app/library/Storage/EloquentRepositories/EloquentMatchRepository.php 1 patch
Braces   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -3,8 +3,7 @@  discard block
 block discarded – undo
3 3
 use \Match as Match;
4 4
 use \Player as Player;
5 5
 
6
-class EloquentMatchRepository implements MatchRepository
7
-{
6
+class EloquentMatchRepository implements MatchRepository {
8 7
   /*Return Score collections that include:
9 8
    * Player Name
10 9
    * Date
@@ -13,7 +12,7 @@  discard block
 block discarded – undo
13 12
    * Multideminsional Array of Hole Numbers and scores   *
14 13
    **/
15 14
 	public function __construct(Match $match, Player $player)
16
-    {
15
+	{
17 16
         $this->match = $match;
18 17
 		$this->player = $player;
19 18
     }
@@ -38,7 +37,8 @@  discard block
 block discarded – undo
38 37
 	{
39 38
 		$dates =  Match::orderBy('date', 'DESC')->get(['date']);
40 39
 		//return $dates;
41
-		$years = $dates->map(function($years){
40
+		$years = $dates->map(function($years)
41
+		{
42 42
 			return substr($years->date, 0, 4);
43 43
 		})->toArray();
44 44
 
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
 
64 64
 		$this->match->save(); //save to match table
65 65
 
66
-		foreach ($matchdata['player'] as $key => $player){
66
+		foreach ($matchdata['player'] as $key => $player) {
67 67
 			$currentPlayer = $this->player->find($player['player_id']);
68 68
 			$attributes = array(
69 69
 				"level_id" => $player['level_id'],
Please login to merge, or discard this patch.