Fix up how extensions are handled.