Locale loader now ignores non-directories

Locales must be stored in directories and the code previously crashed
if there were any unexpected files in the locale folder. Now the code
simply ignores all non-directories.