Skip to content
This repository has been archived by the owner on Mar 14, 2020. It is now read-only.

Commit

Permalink
Merge pull request #32 from Soullivaneuh/secure-option-ternary
Browse files Browse the repository at this point in the history
Ternary conditional for secure option
  • Loading branch information
henrikbjorn committed May 30, 2014
2 parents 0e93e28 + 282e5a3 commit 1a97823
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions GravatarApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,7 @@ public function getUrlForHash($hash, $size = null, $rating = null, $default = nu
'd' => $default ?: $this->defaults['default'],
);

if (null == $secure) {
$secure = $this->defaults['secure'];
}
$secure = $secure ?: $this->defaults['secure'];

return ($secure ? 'https://secure' : 'http://www') . '.gravatar.com/avatar/' . $hash . '?' . http_build_query(array_filter($map));
}
Expand Down

0 comments on commit 1a97823

Please sign in to comment.