Browse Source

fix: Use safe_eval instead eval

version-14
Faris Ansari 4 years ago
parent
commit
355a9e7e7b
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      frappe/sessions.py

+ 1
- 1
frappe/sessions.py View File

@@ -313,7 +313,7 @@ class Session:
""", (self.sid, get_expiry_period_for_query(self.device)))

if rec:
data = frappe._dict(eval(rec and rec[0][1] or '{}'))
data = frappe._dict(frappe.safe_eval(rec and rec[0][1] or '{}'))
data.user = rec[0][0]
else:
self._delete_session()


Loading…
Cancel
Save