Skip to content

Commit

Permalink
Fixed mixed up A::append() and A::prepend()
Browse files Browse the repository at this point in the history
  • Loading branch information
meszaros-lajos-gyorgy committed Jul 25, 2021
1 parent 8a8203a commit 7004381
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/A.php
Original file line number Diff line number Diff line change
Expand Up @@ -108,13 +108,13 @@ public static function ensureArray($data): array
// A::append([4, 5, 6], [1, 2]) -> [1, 2, 4, 5, 6]
public static function append($value, array $data): array
{
return self::concat($data, $value);
return self::concat($value, $data);
}

// A::prepend([4, 5, 6], [1, 2]) -> [4, 5, 6, 1, 2]
public static function prepend($value, array $data): array
{
return self::concat($value, $data);
return self::concat($data, $value);
}

// A::pluck('color', [['color' => 'red', ...], ['color' => 'green', ...]]) -> ['red', 'green']
Expand Down

0 comments on commit 7004381

Please sign in to comment.