Fix PHP-Warning: Invalid argument supplied for foreach()
Merge branch 'master' into paths