Fixing a bug with allowedDomains