if (typeof define === "undefined") {		
    var define = function(fn) {		
        fn(require, exports, module);		
    };		
}

define(function(require, exports, module) {
    "use strict";

    var _ = require("lodash");

    var internalDomain = ['c9.io', 'cloud9beta.com'];

    function hasInternalDomain(email) {
        if (!email) return false;

        var emailElements = email.split("@");
        var emailDomain = emailElements[emailElements.length - 1];

        return _.contains(internalDomain, emailDomain);
    }

    module.exports = hasInternalDomain;
});