make hooks static and add try incase the user isn't using hooks