Skip to content

Commit

Permalink
Avoid using deprecated accessor (uuid as prop) (#96)
Browse files Browse the repository at this point in the history
* Avoid using deprecated accessor (`uuid` as prop)

* Fix phpstan
  • Loading branch information
o0h authored Jul 8, 2021
1 parent ead0957 commit 01337dd
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"require": {
"php": ">=7.2",
"cakephp/cakephp": "^4.0",
"fakerphp/faker": "^1.13",
"fakerphp/faker": "^1.15",
"vierge-noire/cakephp-test-suite-light": "^2.1"
},
"require-dev": {
Expand Down
1 change: 0 additions & 1 deletion src/Factory/BaseFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,6 @@ private function getSaveOptions(): array
*/
protected function persistMany(array $entities)
{
/** @phpstan-ignore-next-line */
return $this->getTable()->saveManyOrFail($entities, $this->getSaveOptions());
}

Expand Down
2 changes: 1 addition & 1 deletion src/Factory/DataCompiler.php
Original file line number Diff line number Diff line change
Expand Up @@ -445,7 +445,7 @@ public function generateRandomPrimaryKey(string $columnType)
switch ($columnType) {
case 'uuid':
case 'string':
$res = $this->getFactory()->getFaker()->uuid;
$res = $this->getFactory()->getFaker()->uuid();
break;
case 'biginteger':
$res = mt_rand(0, intval('9223372036854775807'));
Expand Down

0 comments on commit 01337dd

Please sign in to comment.