Fixed incorrectly displaying loading indicator