Make titanium wait for server