|
@@ -23,7 +23,7 @@ discard block |
|
|
block discarded – undo |
|
23
|
23
|
|
|
24
|
24
|
protected function parseData($tableName, array $data) |
|
25
|
25
|
{ |
|
26
|
|
- $method = 'parseOn' . StringUtils::underscoreToCamelCase($tableName, true); |
|
|
26
|
+ $method = 'parseOn'.StringUtils::underscoreToCamelCase($tableName, true); |
|
27
|
27
|
if (method_exists($this, $method)) { |
|
28
|
28
|
$data = call_user_func_array([$this, $method], [$data]); |
|
29
|
29
|
} |
|
@@ -37,10 +37,10 @@ discard block |
|
|
block discarded – undo |
|
37
|
37
|
if (file_exists($path)) { |
|
38
|
38
|
$ext = pathinfo($path, PATHINFO_EXTENSION); |
|
39
|
39
|
$mimeType = mime_content_type($path); |
|
40
|
|
- $attributes['name'] = pathinfo($path, PATHINFO_FILENAME) . '.' . $ext; |
|
|
40
|
+ $attributes['name'] = pathinfo($path, PATHINFO_FILENAME).'.'.$ext; |
|
41
|
41
|
$attributes['type'] = $mimeType; |
|
42
|
42
|
$content = file_get_contents($path); |
|
43
|
|
- $base64 = 'data:' . $mimeType . ';base64,' . base64_encode($content); |
|
|
43
|
+ $base64 = 'data:'.$mimeType.';base64,'.base64_encode($content); |
|
44
|
44
|
$attributes['data'] = $base64; |
|
45
|
45
|
} else { |
|
46
|
46
|
throw new \Exception('Missing "file" or "data" attribute.'); |
Please login to merge, or discard this patch.