Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

create then save a default empty row #58

Closed
kaemu opened this issue May 1, 2012 · 2 comments
Closed

create then save a default empty row #58

kaemu opened this issue May 1, 2012 · 2 comments
Assignees
Milestone

Comments

@kaemu
Copy link

kaemu commented May 1, 2012

create then save a default empty row
$one = Model::factory('foo')->create();
$one->save();

raises:
Warning: array_fill() : Number of elements must be positive in idiorm.php on line 592

fix

line 591 idiorm.php:
protected function _create_placeholders($number_of_placeholders) {
if ($number_of_placeholders) {
return join(", ", array_fill(0, $number_of_placeholders, "?"));
}
return "";
}

@dr-impossible
Copy link

I've tried out this fix, and it works for me. Thanks!

@ghost ghost assigned treffynnon Nov 8, 2012
@treffynnon
Copy link
Collaborator

This issue is fixed in commit b7da7b8 . Thanks for the patch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants