Skip to content

Commit

Permalink
Fixed translations null bug
Browse files Browse the repository at this point in the history
  • Loading branch information
theahmadzai committed Aug 2, 2017
1 parent 4caef35 commit 83d0429
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/Chapter.php
Original file line number Diff line number Diff line change
Expand Up @@ -248,14 +248,14 @@ public function verse(array $options = [], array $tokens = [])
$options['offset'] = $offset - 1;
if ($limit === 1) {
$options['limit'] = $limit + 1;
} else {

// $limit = $options['limit'];
}
}

$translations = $options['translations'];
if (is_array($translations)) {
if (isset($options['translations'])) {
$translations = $options['translations'];
}

if (!empty($translations) && is_array($translations)) {
array_walk($translations, function ($key, $value, $default = 'translations') use (&$build_query) {
$build_query[] = http_build_query([$default => $key]);
});
Expand Down

0 comments on commit 83d0429

Please sign in to comment.