Skip to content

Commit

Permalink
If user specifies the index manually, respect that
Browse files Browse the repository at this point in the history
  • Loading branch information
baopham committed Jan 29, 2018
1 parent d623fd4 commit 1a2a4f9
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/DynamoDbQueryBuilder.php
Original file line number Diff line number Diff line change
Expand Up @@ -635,6 +635,11 @@ public function toDynamoDbQuery(

$query['TableName'] = $this->model->getTable();

if ($this->index) {
// If user specifies the index manually, respect that
$query['IndexName'] = $this->index;
}

if ($limit !== static::MAX_LIMIT) {
$query['Limit'] = $limit;
}
Expand Down

0 comments on commit 1a2a4f9

Please sign in to comment.