Lint cleanup

Move ensure to the first parameter to stop lint complaints