{"ast":null,"code":"import _objectSpread from \"/home/george/Documents/College/Third Year/CS353/workingserver/studybuddy/node_modules/@babel/runtime/helpers/esm/objectSpread\";\nimport { SIGNUP_SUCCESS, SIGNUP_ERROR, SIGNIN_SUCCESS, SIGNIN_ERROR, EMAIL_NOT_VERIFIED, SIGNOUT_SUCCESS, SIGNOUT_ERROR, RESET_SUCCESS, RESET_ERROR } from \"../actions/actionTypes\";\nconst INITIAL_STATE = {\n  authMsg: \"\"\n};\nexport default function (state = INITIAL_STATE, action) {\n  if (action.type === SIGNIN_SUCCESS || action.type === SIGNOUT_SUCCESS) {\n    return _objectSpread({}, state, {\n      authMsg: \"\"\n    });\n  } else if (action.type === SIGNUP_SUCCESS || action.type === SIGNUP_ERROR || action.type === SIGNIN_ERROR || action.type === EMAIL_NOT_VERIFIED || action.type === SIGNOUT_ERROR || action.type === RESET_SUCCESS || action.type === RESET_ERROR) {\n    return _objectSpread({}, state, {\n      authMsg: action.payload\n    });\n  } else {\n    return state;\n  }\n}","map":{"version":3,"sources":["/home/george/Documents/College/Third Year/CS353/workingserver/studybuddy/src/store/reducers/auth.js"],"names":["SIGNUP_SUCCESS","SIGNUP_ERROR","SIGNIN_SUCCESS","SIGNIN_ERROR","EMAIL_NOT_VERIFIED","SIGNOUT_SUCCESS","SIGNOUT_ERROR","RESET_SUCCESS","RESET_ERROR","INITIAL_STATE","authMsg","state","action","type","payload"],"mappings":";AAAA,SACEA,cADF,EAEEC,YAFF,EAGEC,cAHF,EAIEC,YAJF,EAKEC,kBALF,EAMEC,eANF,EAOEC,aAPF,EAQEC,aARF,EASEC,WATF,QAUO,wBAVP;AAYA,MAAMC,aAAa,GAAG;AACpBC,EAAAA,OAAO,EAAE;AADW,CAAtB;AAIA,eAAe,UAASC,KAAK,GAAGF,aAAjB,EAAgCG,MAAhC,EAAwC;AACrD,MAAIA,MAAM,CAACC,IAAP,KAAgBX,cAAhB,IAAkCU,MAAM,CAACC,IAAP,KAAgBR,eAAtD,EAAuE;AACrE,6BAAYM,KAAZ;AAAmBD,MAAAA,OAAO,EAAE;AAA5B;AACD,GAFD,MAEO,IACLE,MAAM,CAACC,IAAP,KAAgBb,cAAhB,IACAY,MAAM,CAACC,IAAP,KAAgBZ,YADhB,IAEAW,MAAM,CAACC,IAAP,KAAgBV,YAFhB,IAGAS,MAAM,CAACC,IAAP,KAAgBT,kBAHhB,IAIAQ,MAAM,CAACC,IAAP,KAAgBP,aAJhB,IAKAM,MAAM,CAACC,IAAP,KAAgBN,aALhB,IAMAK,MAAM,CAACC,IAAP,KAAgBL,WAPX,EAQL;AACA,6BAAYG,KAAZ;AAAmBD,MAAAA,OAAO,EAAEE,MAAM,CAACE;AAAnC;AACD,GAVM,MAUA;AACL,WAAOH,KAAP;AACD;AACF","sourcesContent":["import {\n  SIGNUP_SUCCESS,\n  SIGNUP_ERROR,\n  SIGNIN_SUCCESS,\n  SIGNIN_ERROR,\n  EMAIL_NOT_VERIFIED,\n  SIGNOUT_SUCCESS,\n  SIGNOUT_ERROR,\n  RESET_SUCCESS,\n  RESET_ERROR\n} from \"../actions/actionTypes\";\n\nconst INITIAL_STATE = {\n  authMsg: \"\"\n};\n\nexport default function(state = INITIAL_STATE, action) {\n  if (action.type === SIGNIN_SUCCESS || action.type === SIGNOUT_SUCCESS) {\n    return { ...state, authMsg: \"\" };\n  } else if (\n    action.type === SIGNUP_SUCCESS ||\n    action.type === SIGNUP_ERROR ||\n    action.type === SIGNIN_ERROR ||\n    action.type === EMAIL_NOT_VERIFIED ||\n    action.type === SIGNOUT_ERROR ||\n    action.type === RESET_SUCCESS ||\n    action.type === RESET_ERROR\n  ) {\n    return { ...state, authMsg: action.payload };\n  } else {\n    return state;\n  }\n}\n"]},"metadata":{},"sourceType":"module"}