Remove unneeded directory check in filename-based cache busting

I know this technique can be used to bust whole dirs, but that is not the case in this code sample.