mirror of https://github.com/portainer/portainer
fix(login) hide password in console EE-5279 (#8774)
parent
ae339a0047
commit
0f9a0e25f2
|
@ -47,8 +47,10 @@ export function notifyError(title: string, e?: Error, fallbackText = '') {
|
||||||
const msg = pickErrorMsg(e) || fallbackText;
|
const msg = pickErrorMsg(e) || fallbackText;
|
||||||
saveNotification(title, msg, 'error');
|
saveNotification(title, msg, 'error');
|
||||||
|
|
||||||
|
if (!_.get(e, 'resource.password')) {
|
||||||
// eslint-disable-next-line no-console
|
// eslint-disable-next-line no-console
|
||||||
console.error(e);
|
console.error(e);
|
||||||
|
}
|
||||||
|
|
||||||
if (msg !== 'Invalid JWT token') {
|
if (msg !== 'Invalid JWT token') {
|
||||||
toastr.error(sanitize(_.escape(msg)), sanitize(title), { timeOut: 6000 });
|
toastr.error(sanitize(_.escape(msg)), sanitize(title), { timeOut: 6000 });
|
||||||
|
|
Loading…
Reference in New Issue