Skip to content
This repository was archived by the owner on Jan 29, 2020. It is now read-only.

Commit d212e3a

Browse files
committed
Merge branch 'hotfix/377' into develop
Forward port #377
2 parents 4a99296 + a8adf67 commit d212e3a

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,8 @@ All notable changes to this project will be documented in this file, in reverse
5252

5353
- [#375](https://github.com/zendframework/zend-db/pull/375) fixes detecting number of replacements in `Zend\Db\Sql\Expression`.
5454

55+
- [#377](https://github.com/zendframework/zend-db/pull/377) allows any `AdapterInterface` instance in `RowGateway`.
56+
5557
## 2.10.0 - 2019-02-25
5658

5759
### Added

src/RowGateway/RowGateway.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
namespace Zend\Db\RowGateway;
1111

12-
use Zend\Db\Adapter\Adapter;
12+
use Zend\Db\Adapter\AdapterInterface;
1313
use Zend\Db\Sql\Sql;
1414

1515
class RowGateway extends AbstractRowGateway
@@ -19,7 +19,7 @@ class RowGateway extends AbstractRowGateway
1919
*
2020
* @param string $primaryKeyColumn
2121
* @param string|\Zend\Db\Sql\TableIdentifier $table
22-
* @param Adapter|Sql $adapterOrSql
22+
* @param AdapterInterface|Sql $adapterOrSql
2323
* @throws Exception\InvalidArgumentException
2424
*/
2525
public function __construct($primaryKeyColumn, $table, $adapterOrSql = null)
@@ -33,7 +33,7 @@ public function __construct($primaryKeyColumn, $table, $adapterOrSql = null)
3333
// set Sql object
3434
if ($adapterOrSql instanceof Sql) {
3535
$this->sql = $adapterOrSql;
36-
} elseif ($adapterOrSql instanceof Adapter) {
36+
} elseif ($adapterOrSql instanceof AdapterInterface) {
3737
$this->sql = new Sql($adapterOrSql, $this->table);
3838
} else {
3939
throw new Exception\InvalidArgumentException('A valid Sql object was not provided.');

0 commit comments

Comments
 (0)