Refactor hooks a bit