Skip to content

Commit

Permalink
Return NULL if undefined
Browse files Browse the repository at this point in the history
Throwing an exception is not how it is done elsewhere
in the framework, so replaced that by returning NULL
for consistency.
  • Loading branch information
jadb committed May 28, 2015
1 parent 31e41d5 commit 54f6990
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Mailer/Mailer.php
Expand Up @@ -204,7 +204,7 @@ public function offsetExists($offset)
public function offsetGet($offset)
{
if (!$this->offsetExists($offset)) {
throw \Exception();
return null;
}

if (isset($this->{$offset})) {
Expand Down

0 comments on commit 54f6990

Please sign in to comment.