Test Setup Failed
Push — master ( c9dde2...c96a31 )
by Craig
03:54
created
src/Ams/Article/CategoryAsset.php 2 patches
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -22,11 +22,11 @@
 block discarded – undo
22 22
 			'required' => true
23 23
 		),
24 24
 		'status' => array(
25
-            'name' => 'Published',
26
-            'type' => self::DROPDOWN,
25
+			'name' => 'Published',
26
+			'type' => self::DROPDOWN,
27 27
 			 'options' => ['published' => 'Published', 'unpublished' => 'Unpublished'],
28 28
 			 'published' => ['published']
29
-        ),
29
+		),
30 30
 
31 31
 	);
32 32
 
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -40,7 +40,7 @@
 block discarded – undo
40 40
 	/**
41 41
 	 * generate the route for this asset
42 42
 	 */
43
-	public static function route($record, $path = null){
43
+	public static function route($record, $path = null) {
44 44
 		$page = $record->page;
45 45
 		return route('frontend.ams.article.category', ['slug' => $page->slug]);
46 46
 	}
Please login to merge, or discard this patch.
src/Ams/AutoCallBackAsset.php 1 patch
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -5,12 +5,12 @@
 block discarded – undo
5 5
 
6 6
 class AutoCallBackAsset extends Asset {
7 7
 
8
-    public $type = AutoCallBackAsset::class;
9
-    public $namespace = 'property';
8
+	public $type = AutoCallBackAsset::class;
9
+	public $namespace = 'property';
10 10
 
11
-    public static function html($data) {
11
+	public static function html($data) {
12 12
 		$content = explode('|', $data['meta']);
13
-        return '<span>' . $content[1] . '</span>';
13
+		return '<span>' . $content[1] . '</span>';
14 14
 	}
15 15
 
16 16
 
Please login to merge, or discard this patch.
src/Ams/ImageAsset.php 3 patches
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@  discard block
 block discarded – undo
8 8
 
9 9
 class ImageAsset extends Asset {
10 10
 
11
-    public $type = ImageAsset::class;
11
+	public $type = ImageAsset::class;
12 12
 	public $namespace = 'property';
13 13
 
14 14
 	public static function getImageUrl($filename, $width = null, $height = null){
@@ -36,10 +36,10 @@  discard block
 block discarded – undo
36 36
 
37 37
 	}
38 38
 
39
-    public static function html($data) {
39
+	public static function html($data) {
40 40
 
41 41
 		return '<img src="' . self::getImageUrl($data['value']) . '" />';
42
-    }
42
+	}
43 43
 
44 44
 
45 45
 
Please login to merge, or discard this patch.
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -11,23 +11,23 @@
 block discarded – undo
11 11
     public $type = ImageAsset::class;
12 12
 	public $namespace = 'property';
13 13
 
14
-	public static function getImageUrl($filename, $width = null, $height = null){
14
+	public static function getImageUrl($filename, $width = null, $height = null) {
15 15
 
16
-		$imagePath = public_path().'/vendor/phpsa-datastore/';
16
+		$imagePath = public_path() . '/vendor/phpsa-datastore/';
17 17
 
18 18
 		if ($width || $height) {
19
-			$path = 'thumbs/' . $width .  'x' . $height  . '.' . $filename;
19
+			$path = 'thumbs/' . $width . 'x' . $height . '.' . $filename;
20 20
 
21
-			if(!is_file($imagePath . $path)){
22
-				try{
23
-					Image::make(public_path().'/vendor/phpsa-datastore/img/' . $filename)->resize($width,$height, function ($constraint) {
21
+			if (!is_file($imagePath . $path)) {
22
+				try {
23
+					Image::make(public_path() . '/vendor/phpsa-datastore/img/' . $filename)->resize($width, $height, function($constraint) {
24 24
 						$constraint->aspectRatio();
25 25
 					})->save($imagePath . $path);
26
-				}catch(Exception $e){
26
+				}catch (Exception $e) {
27 27
 					//Silent fallback as the image does not exist!
28 28
 				}
29 29
 			}
30
-		}else{
30
+		}else {
31 31
 			$path = 'img/' . $filename;
32 32
 		}
33 33
 		return '/vendor/phpsa-datastore/' . $path;
Please login to merge, or discard this patch.
Braces   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -23,11 +23,11 @@
 block discarded – undo
23 23
 					Image::make(public_path().'/vendor/phpsa-datastore/img/' . $filename)->resize($width,$height, function ($constraint) {
24 24
 						$constraint->aspectRatio();
25 25
 					})->save($imagePath . $path);
26
-				}catch(Exception $e){
26
+				} catch(Exception $e){
27 27
 					//Silent fallback as the image does not exist!
28 28
 				}
29 29
 			}
30
-		}else{
30
+		} else{
31 31
 			$path = 'img/' . $filename;
32 32
 		}
33 33
 		return '/vendor/phpsa-datastore/' . $path;
Please login to merge, or discard this patch.
src/Ams/SubHeadingAsset.php 1 patch
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -5,11 +5,11 @@
 block discarded – undo
5 5
 
6 6
 class SubHeadingAsset extends Asset {
7 7
 
8
-    public $shortname = 'SubHeading';
9
-    public $type = SubHeadingAsset::class;
10
-    public $namespace = 'property';
8
+	public $shortname = 'SubHeading';
9
+	public $type = SubHeadingAsset::class;
10
+	public $namespace = 'property';
11 11
 
12
-    public static function html($data) {
13
-        return '<h4>' . $data['value'] . '</h4>';
14
-    }
12
+	public static function html($data) {
13
+		return '<h4>' . $data['value'] . '</h4>';
14
+	}
15 15
 }
16 16
\ No newline at end of file
Please login to merge, or discard this patch.
src/Ams/FileAsset.php 1 patch
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -6,12 +6,12 @@
 block discarded – undo
6 6
 
7 7
 class FileAsset extends Asset {
8 8
 
9
-    public $type = FileAsset::class;
10
-    public $namespace = 'property';
9
+	public $type = FileAsset::class;
10
+	public $namespace = 'property';
11 11
 
12
-    public static function html($data) {
13
-        return Storage::url($data['value']);
14
-    }
12
+	public static function html($data) {
13
+		return Storage::url($data['value']);
14
+	}
15 15
 
16 16
 
17 17
 }
Please login to merge, or discard this patch.
src/Ams/AutoCallBackAdderAsset.php 2 patches
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -5,16 +5,16 @@
 block discarded – undo
5 5
 
6 6
 class AutoCallBackAdderAsset extends Asset {
7 7
 
8
-    public $type = AutoCallBackAdderAsset::class;
9
-    public $namespace = 'property';
8
+	public $type = AutoCallBackAdderAsset::class;
9
+	public $namespace = 'property';
10 10
 
11
-    public static function html($data) {
11
+	public static function html($data) {
12 12
 		$strings = [];
13 13
 
14 14
 		foreach($data['meta'] as $k){
15 15
 			$parts = explode("|", $k);
16 16
 			$strings[] = $parts[1];
17 17
 		}
18
-        return '<span>' . implode(", ", $strings) . '</span>';
19
-    }
18
+		return '<span>' . implode(", ", $strings) . '</span>';
19
+	}
20 20
 }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -11,7 +11,7 @@
 block discarded – undo
11 11
     public static function html($data) {
12 12
 		$strings = [];
13 13
 
14
-		foreach($data['meta'] as $k){
14
+		foreach ($data['meta'] as $k) {
15 15
 			$parts = explode("|", $k);
16 16
 			$strings[] = $parts[1];
17 17
 		}
Please login to merge, or discard this patch.
src/Ams/StringAsset.php 1 patch
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -5,10 +5,10 @@
 block discarded – undo
5 5
 
6 6
 class StringAsset extends Asset {
7 7
 
8
-    public $type = StringAsset::class;
9
-    public $namespace = 'property';
8
+	public $type = StringAsset::class;
9
+	public $namespace = 'property';
10 10
 
11
-    public static function html($data) {
12
-        return '<span>' . $data['value'] . '</span> STRING';
13
-    }
11
+	public static function html($data) {
12
+		return '<span>' . $data['value'] . '</span> STRING';
13
+	}
14 14
 }
Please login to merge, or discard this patch.
src/Ams/MetatextAsset.php 1 patch
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -5,11 +5,11 @@
 block discarded – undo
5 5
 
6 6
 class MetatextAsset extends Asset {
7 7
 
8
-    public $type = MetatextAsset::class;
9
-    public $namespace = 'property';
8
+	public $type = MetatextAsset::class;
9
+	public $namespace = 'property';
10 10
 
11
-    public static function html($data) {
12
-        return '<p>' . $data['value'] . '</p>';
13
-    }
11
+	public static function html($data) {
12
+		return '<p>' . $data['value'] . '</p>';
13
+	}
14 14
 
15 15
 }
Please login to merge, or discard this patch.
src/Ams/HeadingAsset.php 1 patch
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -5,11 +5,11 @@
 block discarded – undo
5 5
 
6 6
 class HeadingAsset extends Asset {
7 7
 
8
-    public $shortname = 'Heading';
9
-    public $type = HeadingAsset::class;
10
-    public $namespace = 'property';
8
+	public $shortname = 'Heading';
9
+	public $type = HeadingAsset::class;
10
+	public $namespace = 'property';
11 11
 
12
-    public static function html($data) {
13
-        return '<h3>' . $data['value'] . '</h3>';
14
-    }
12
+	public static function html($data) {
13
+		return '<h3>' . $data['value'] . '</h3>';
14
+	}
15 15
 }
16 16
\ No newline at end of file
Please login to merge, or discard this patch.