| Index: lib/tldjs.js |
| =================================================================== |
| --- a/lib/tldjs.js |
| +++ b/lib/tldjs.js |
| @@ -14,25 +14,23 @@ |
| * You should have received a copy of the GNU General Public License |
| * along with Adblock Plus. If not, see <http://www.gnu.org/licenses/>. |
| */ |
| /* global publicSuffixes */ |
| /** @module tldjs */ |
| -"use strict"; |
| - |
| /** |
| * Get the base domain for given hostname. |
| * |
| * @param {string} hostname |
| * @return {string} |
| */ |
| -exports.getDomain = hostname => |
| +export const getDomain = hostname => |
| { |
| let bits = hostname.split("."); |
| let cutoff = bits.length - 2; |
| for (let i = 0; i < bits.length; i++) |
| { |
| let offset = publicSuffixes[bits.slice(i).join(".")]; |