Refactored CFileHelper to reuse the getExtension method

Reusing a method that we already declare.  I've run the unit tests.