Only do str_replace if $file is actually a string.
Only do str_replace if $file is actually a string.

UnderDogg/whoops,stefen/whoops,nonconforme/whoops,staabm/whoops,oligriffiths/whoops,oligriffiths/whoops,Vmak11/whoops,filp/whoops,filp/whoops,staabm/whoops,emilkje/whoops,stefen/whoops,michabbb-backup/whoops,emilkje/whoops,nonconforme/whoops,Vmak11/whoops,michabbb-backup/whoops,UnderDogg/whoops