Skip to content
This repository has been archived by the owner on Jun 28, 2022. It is now read-only.

Commit

Permalink
Merge pull request scandipwa#4947 from leonazava/4660-2
Browse files Browse the repository at this point in the history
[4660] - login fields don't disappear on checkout after sign-in from header - fixed
  • Loading branch information
carinadues authored Jun 23, 2022
2 parents 3f60152 + 4375a0f commit 2e51123
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ import { BILLING_STEP } from 'Route/Checkout/Checkout.config';
import { Addresstype } from 'Type/Account.type';
import { CheckoutStepType, PaymentMethodsType } from 'Type/Checkout.type';
import { TotalsType } from 'Type/MiniCart.type';
import { isSignedIn } from 'Util/Auth';
import { formatPrice } from 'Util/Price';

import './CheckoutBilling.style';
Expand Down Expand Up @@ -56,7 +57,6 @@ export class CheckoutBilling extends PureComponent {
onCreateUserChange: PropTypes.func.isRequired,
onPasswordChange: PropTypes.func.isRequired,
isGuestEmailSaved: PropTypes.bool.isRequired,
isSignedIn: PropTypes.bool.isRequired,
shippingAddress: Addresstype.isRequired,
termsAndConditions: PropTypes.arrayOf(PropTypes.shape({
checkbox_text: PropTypes.string
Expand Down Expand Up @@ -111,12 +111,11 @@ export class CheckoutBilling extends PureComponent {
onEmailChange,
onCreateUserChange,
onPasswordChange,
isGuestEmailSaved,
isSignedIn
isGuestEmailSaved
} = this.props;
const isBilling = checkoutStep === BILLING_STEP;

if (isSignedIn) {
if (isSignedIn()) {
return null;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import { BILLING_STEP, SHIPPING_STEP } from 'Route/Checkout/Checkout.config';
import { Addresstype } from 'Type/Account.type';
import { CheckoutStepType, ShippingMethodsType, ShippingMethodType } from 'Type/Checkout.type';
import { TotalsType } from 'Type/MiniCart.type';
import { isSignedIn } from 'Util/Auth';
import { getAllCartItemsSku } from 'Util/Cart';
import { formatPrice } from 'Util/Price';

Expand Down Expand Up @@ -52,8 +53,7 @@ export class CheckoutShipping extends PureComponent {
onEmailChange: PropTypes.func.isRequired,
onCreateUserChange: PropTypes.func.isRequired,
onPasswordChange: PropTypes.func.isRequired,
isGuestEmailSaved: PropTypes.bool.isRequired,
isSignedIn: PropTypes.bool.isRequired
isGuestEmailSaved: PropTypes.bool.isRequired
};

static defaultProps = {
Expand Down Expand Up @@ -199,12 +199,11 @@ export class CheckoutShipping extends PureComponent {
onEmailChange,
onCreateUserChange,
onPasswordChange,
isGuestEmailSaved,
isSignedIn
isGuestEmailSaved
} = this.props;
const isBilling = checkoutStep === BILLING_STEP;

if (isSignedIn) {
if (isSignedIn()) {
return null;
}

Expand Down

0 comments on commit 2e51123

Please sign in to comment.