Make GET handler more robust