better error handling with reddit api