6 lines
219 B
JavaScript
6 lines
219 B
JavaScript
function userData() {
|
|
if (document.getElementsByTagName('body')[0].getAttribute('data-user') === null) {
|
|
return null;
|
|
}
|
|
return JSON.parse(document.getElementsByTagName('body')[0].getAttribute('data-user'));
|
|
}
|