Skip to content

Commit

Permalink
chore: don't fail logout if cookie is not found
Browse files Browse the repository at this point in the history
  • Loading branch information
jonas-jonas committed Apr 15, 2024
1 parent eb67bed commit 62d9709
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions test/e2e/cypress/support/commands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -922,8 +922,9 @@ Cypress.Commands.add("logout", () => {
const c = cookies.find(
({ name }) => name.indexOf("ory_kratos_session") > -1,
)
expect(c).to.not.be.undefined
cy.clearCookie(c.name)
if (c) {
cy.clearCookie(c.name)
}
})
cy.noSession()
})
Expand Down

0 comments on commit 62d9709

Please sign in to comment.