Fix custom hook output and return values