Factor out second set of extension checks
Challenge 8