https://cypress.io logo
How to prevent logging session user credentials?
# i-need-help
e
I need to prevent the user credentials from being logged for security reasons - how can this be done?

https://cdn.discordapp.com/attachments/1106530498148319314/1106530498307686420/Screenshot_2023-05-12_at_12.32.36.png

e
From the docs: > The id provided to cy.session() will display in the reporter, thus we do not recommend using sensitive data like passwords or tokens as unique identifiers.
Try
user.username
instead of the whole
user
object
e
Thanks again @echoing-kangaroo-83836 - all working now 🙂
e
Awesome 🙂
2 Views