Skip to content

Commit

Permalink
Merge pull request #11 from immanuelfodor/patch-1
Browse files Browse the repository at this point in the history
Fix broken css/js files on individual shaare pages
  • Loading branch information
ilesinge authored Sep 6, 2020
2 parents 7a3c69e + eff52e2 commit 968c92e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions related/related.php
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ function hook_related_render_includes($data)
// Note that you just need to specify CSS path.
global $routerClass;
if ($data['_PAGE_'] == $routerClass::$PAGE_LINKLIST) {
$data['css_files'][] = PluginManager::$PLUGINS_PATH . '/related/related.css';
$data['css_files'][] = ($data['_BASE_PATH_'] ?? '') . '/' . PluginManager::$PLUGINS_PATH . '/related/related.css';
}

return $data;
Expand Down Expand Up @@ -248,7 +248,7 @@ function hook_related_render_footer($data)
// Note that you just need to specify CSS path.
global $routerClass;
if ($data['_PAGE_'] == $routerClass::$PAGE_LINKLIST) {
$data['js_files'][] = PluginManager::$PLUGINS_PATH . '/related/related.js';
$data['js_files'][] = ($data['_BASE_PATH_'] ?? '') . '/' . PluginManager::$PLUGINS_PATH . '/related/related.js';
}

return $data;
Expand Down

0 comments on commit 968c92e

Please sign in to comment.