148 |
148 |
149 @param host host to check for (string) |
149 @param host host to check for (string) |
150 @return flag indicating presence in the whitelist (boolean) |
150 @return flag indicating presence in the whitelist (boolean) |
151 """ |
151 """ |
152 return host in self.__whitelist or \ |
152 return host in self.__whitelist or \ |
153 "www." + host in self.__whitelist or \ |
153 "www." + host in self.__whitelist or \ |
154 host.replace("www.", "") in self.__whitelist |
154 host.replace("www.", "") in self.__whitelist |
155 |
155 |
156 def addToWhitelist(self, host): |
156 def addToWhitelist(self, host): |
157 """ |
157 """ |
158 Public method to add a host to the whitelist. |
158 Public method to add a host to the whitelist. |
159 |
159 |