changed formatting
added missing check for CATALOG_ACCEPT_EXTENSION