bug fix-ensure that we return extensions

bug fix for proper handling of extensions