hide loading widget after post request or failed validation