mario-core 2.9.415-feedback → 2.9.416-release

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -39651,7 +39651,7 @@ var BlockLogin = function BlockLogin(_ref) {
39651
39651
 
39652
39652
  var onSuccessGoogle = function onSuccessGoogle(res) {
39653
39653
  if (!!(res !== null && res !== void 0 && res.accessToken)) {
39654
- var _hostName$split, _email$split;
39654
+ var _hostName$split, _email$split, _extensionEmail$split, _extensionEmail$split2;
39655
39655
 
39656
39656
  var _res$profileObj = res.profileObj,
39657
39657
  email = _res$profileObj.email,
@@ -39664,8 +39664,15 @@ var BlockLogin = function BlockLogin(_ref) {
39664
39664
  var hostName = window.location.hostname;
39665
39665
  var subDomain = (_hostName$split = hostName.split(".marioforme.com")) === null || _hostName$split === void 0 ? void 0 : _hostName$split[0];
39666
39666
  var emailDomain = (_email$split = email.split("@")) === null || _email$split === void 0 ? void 0 : _email$split[1];
39667
+ var matchExtension = extensionEmail === null || extensionEmail === void 0 ? void 0 : (_extensionEmail$split = extensionEmail.split(",")) === null || _extensionEmail$split === void 0 ? void 0 : (_extensionEmail$split2 = _extensionEmail$split.map(function (x) {
39668
+ return x.trim();
39669
+ })) === null || _extensionEmail$split2 === void 0 ? void 0 : _extensionEmail$split2.filter(function (x) {
39670
+ return x;
39671
+ }).some(function (ext) {
39672
+ return emailDomain.includes(ext);
39673
+ });
39667
39674
 
39668
- if (!emailDomain.includes(subDomain) && !emailDomain.includes(extensionEmail)) {
39675
+ if (!emailDomain.includes(subDomain) && !matchExtension) {
39669
39676
  alert("The email address you used does not match the login information in the database. Please check that you are using your school assigned email address to log into MARIO for Me. If you have further trouble please notify your school site administrator");
39670
39677
  return;
39671
39678
  }