Skip to content
This repository has been archived by the owner on Dec 27, 2023. It is now read-only.

Bug #0011704 / PHP 7 can't decode empty JSON #11

Closed
wants to merge 8 commits into from
Closed

Bug #0011704 / PHP 7 can't decode empty JSON #11

wants to merge 8 commits into from

Conversation

lab-at-nohl
Copy link
Member

https://forge.tine20.org/view.php?id=11704

Function parameters are passed as json or object from time to time. At least PHP 7 (tested) can't handle empty strings as JSON; propably PHP 5.6.5 as well (https://bugs.php.net/bug.php?id=68938).

Sync tine20 after 2015.07.5
Sync tine20 after 2015.07.7
Sync tine20 after 2016.03.1
Invented function _prepareParameter to make sure JSON string at least consists of '{}' since PHP 7 and some PHP 5.6.5 (https://bugs.php.net/bug.php?id=68938) return syntax error if sting is empty.
@pschuele
Copy link
Member

hi Johannes,
thanks for the patch. we just stumbled across this yesterday as well.
the fix looks perfect! I'll add a test for this as well.
but one thing about the pull request: could you remove the 3 "merge pull request" commits from it?
perhaps you should reset your master to our master and just put the relevant commit there (maybe this helps:http://stackoverflow.com/questions/20765030/git-remove-a-commit-from-pull-request).
thanks a lot!
Philipp

@pschuele pschuele self-assigned this Mar 21, 2016
@lab-at-nohl
Copy link
Member Author

I'll send a new pull request.

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

Successfully merging this pull request may close these issues.

None yet

2 participants