Fix maploader problem because of setTimeout