improve function signatures for php strictness
Merge remote-tracking branch 'origin/master'