Made the hook more readable