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

Fix for parameter types. #206

Merged
merged 6 commits into from
Jun 3, 2014
Merged

Fix for parameter types. #206

merged 6 commits into from
Jun 3, 2014

Conversation

charsleysa
Copy link
Contributor

Solves #196

@treffynnon
Copy link
Collaborator

Not sure that we can always assume is_numeric is an integer. What about
float values?

Not sure about defaulting to null on execute rather than an empty array
instead. Is there a reason for this?
On May 29, 2014 7:38 AM, "Stefan Andres Charsley" notifications@github.com
wrote:

Solves #196 #196

You can merge this Pull Request by running

git pull https://github.com/charsleysa/idiorm develop

Or view, comment on, or merge it at:

#206
Commit Summary

  • Fix for parameter types.

File Changes

Patch Links:


Reply to this email directly or view it on GitHub
#206.

@charsleysa
Copy link
Contributor Author

Good call on the is_numeric I'll patch that.

As for defaulting to null on execute, thats only used in the Mock PDO Statement object and is so that it's easy to differentiate when someone passes an array to the function.

The variable gets replaced if its NULL and if it's an array it gets left alone.

Only make integers type int, all other number types get passed as
strings.
@ghost
Copy link

ghost commented May 29, 2014

Why is $parameters[$i] = +($parameters[$i]); necessary, if is_int() returned true?

@treffynnon
Copy link
Collaborator

@charsleysa the question from @cainmi was going to be my very next question now I am in front of a computer again instead of on my phone.

@charsleysa
Copy link
Contributor Author

Sorry, habit from Javascript, will patch.

treffynnon added a commit that referenced this pull request Jun 3, 2014
@treffynnon treffynnon merged commit f8f46c0 into j4mie:develop Jun 3, 2014
@ghost ghost mentioned this pull request Jun 8, 2014
@ghost ghost mentioned this pull request Jun 18, 2014
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

Successfully merging this pull request may close these issues.

3 participants