Remove unused getExtension function