Added loading modal while waiting for promise to be returned