@@ -64,28 +64,14 @@ class Gravatar implements Contracts\Gravatar
6464 *
6565 * @var array
6666 */
67- private $ supportedImages = [
68- '404 ' , // Do not load any image if none is associated with the email hash,
69- // instead return an HTTP 404 response
70- 'mm ' , // (mystery-man) a simple, cartoon-style silhouetted outline of a person.
71- 'identicon ' , // a geometric pattern based on an email hash
72- 'monsterid ' , // a generated 'monster' with different colors, faces, etc
73- 'wavatar ' , // generated faces with differing features and backgrounds
74- 'retro ' , // awesome generated, 8-bit arcade-style pixelated faces
75- // 'blank',
76- ];
67+ private $ supportedImages = ['404 ' , 'mm ' , 'identicon ' , 'monsterid ' , 'wavatar ' , 'retro ' ];
7768
7869 /**
7970 * Supported image ratings.
8071 *
8172 * @var array
8273 */
83- private $ supportedRatings = [
84- 'g ' , // suitable for display on all websites with any audience type.
85- 'pg ' , // may contain rude gestures, provocatively dressed individuals, the lesser swear words, or mild violence.
86- 'r ' , // may contain such things as harsh profanity, intense violence, nudity, or hard drug use.
87- 'x ' // may contain hardcore sexual imagery or extremely disturbing violence.
88- ];
74+ private $ supportedRatings = ['g ' , 'pg ' , 'r ' , 'x ' ];
8975
9076 /* -----------------------------------------------------------------
9177 | Constructor
@@ -270,7 +256,7 @@ public function get($email, $hash = true)
270256
271257 $ params = $ this ->getParams ($ email );
272258
273- return $ url . '? ' . http_build_query ($ params );
259+ return $ url. '? ' . http_build_query ($ params );
274260 }
275261
276262 /**
@@ -293,9 +279,9 @@ public function image($email, $alt = null, array $attributes = [], $rating = nul
293279 ? min (512 , max ($ dimensions ))
294280 : $ this ->getSize ();
295281
296- $ src = $ this -> src ( $ email , $ size , $ rating );
297-
298- return HtmlBuilder:: image ( $ src , $ alt , $ attributes );
282+ return HtmlBuilder:: image (
283+ $ this -> src ( $ email , $ size , $ rating ), $ alt , $ attributes
284+ );
299285 }
300286
301287 /**
0 commit comments