fix leftover extension handling