I haven't noticed that getFilenameExtension is exported function, I was sure it is only used locally in this file.