Skip to content

Commit 1533c34

Browse files
authored
Merge branch 'octobroid:master' into develop
2 parents 6252d3c + b3a0b75 commit 1533c34

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

classes/ApiController.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,11 @@ public function __construct(Manager $fractal)
4848
$this->input = request()->isJson() ? request()->json() : request();
4949
$this->data = $this->input->all();
5050

51+
// Always add CORS for every request
52+
header("Access-Control-Allow-Origin: *");
53+
5154
// Handle error
5255
App::error(function(\Exception $e) {
53-
header("Access-Control-Allow-Origin: *");
5456
$trace = $e->getTraceAsString();
5557

5658
$error = [

classes/Transformer.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,12 +149,12 @@ protected function files($files)
149149
return $result;
150150
}
151151

152-
protected function images($files, Array $customSizes = [])
152+
protected function images($files, Array $customSizes = [], $replace = false)
153153
{
154154
$result = [];
155155

156156
foreach ($files as $file) {
157-
$result[] = $this->image($file);
157+
$result[] = $this->image($file, $customSizes, $replace);
158158
}
159159

160160
return $result;

0 commit comments

Comments
 (0)