baumrock / RockMigrations

The Ultimate Automation and Deployment-Tool for ProcessWire
MIT License
34 stars 10 forks source link

Argument in function createPage() #33

Closed Mikhail-Kalinin2 closed 1 year ago

Mikhail-Kalinin2 commented 1 year ago

Hello, @BernhardBaumrock!

In function createPage() in RockMigrations.module.php:1076 there is an argument with strict typization: array $status. However, $status should be typized as int, since status should be integer.

Can you please fix it?

BernhardBaumrock commented 1 year ago

Thx for the report, the idea is to define the status as array. I've updated the docblock:

   * Usage:
   * $rm->createPage(
   *   template: 'foo',
   *   title: 'My foo page',
   *   parent: 1,
   *   status: ['hidden'],
   * );

Feel free to reopen the issue if you think that's still something to fix.

BernhardBaumrock commented 1 year ago

close