Skip to content

Commit e6dd35b

Browse files
committed
Fix using language parameter instead of global user object
1 parent b268332 commit e6dd35b

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

h5peditor-ajax.class.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,10 +118,9 @@ public function action($endpoint) {
118118

119119
case H5PEditorEndpoints::CONTENT_HUB_METADATA_CACHE:
120120
if (!$this->isHubOn()) return;
121-
global $user;
122121
header('Cache-Control: no-cache');
123122
header('Content-Type: application/json; charset=utf-8');
124-
print '{"success":true,"data":' . $this->core->getUpdatedContentHubMetadataCache($user->language) . '}';
123+
print '{"success":true,"data":' . $this->core->getUpdatedContentHubMetadataCache(func_get_arg(1)) . '}';
125124
break;
126125

127126
case H5PEditorEndpoints::LIBRARY_INSTALL:

0 commit comments

Comments
 (0)