Merged PR 2533: made petemail from server side var for logged in
made petemail from server side var for logged in Related work items: #24215
This commit is contained in:
@@ -527,11 +527,21 @@ const mapStateToProps = (state) => {
|
||||
return {
|
||||
accountDetails: state.accountDetails,
|
||||
typeOfContactValue,
|
||||
initialValues: email ? { contactEmail: email } : {},
|
||||
petEmail: process.env.NEXT_PUBLIC_PETEMAIL
|
||||
initialValues: email ? { contactEmail: email } : {}
|
||||
};
|
||||
};
|
||||
|
||||
export const getServerSideProps = wrapper.getServerSideProps(
|
||||
(store) => async (ctx) => {
|
||||
const { req, locale } = ctx;
|
||||
return {
|
||||
props: {
|
||||
petEmail: process.env.PETEMAIL
|
||||
}
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
export default connect(
|
||||
mapStateToProps,
|
||||
mapDispatchToProps
|
||||
|
||||
Reference in New Issue
Block a user