diff --git a/src/freedombone-app-fedwiki b/src/freedombone-app-fedwiki index cbb9c0ed..02766eb2 100755 --- a/src/freedombone-app-fedwiki +++ b/src/freedombone-app-fedwiki @@ -48,6 +48,12 @@ fedwiki_variables=(FEDWIKI_DOMAIN_NAME MY_USERNAME MY_EMAIL_ADDRESS) +function fedwiki_remove_bad_links { + if [ -f /usr/local/lib/node_modules/wiki/node_modules/wiki-security-friends/client/security.js ]; then + sed -i 's|maxcdn.bootstrapcdn.com|localhost|g' /usr/local/lib/node_modules/wiki/node_modules/wiki-security-friends/client/security.js + fi +} + function logging_on_fedwiki { echo -n '' } @@ -109,6 +115,7 @@ function upgrade_fedwiki { systemctl stop fedwiki npm upgrade -g wiki@$FEDWIKI_VERSION + fedwiki_remove_bad_links chown -R fedwiki:fedwiki $FEDWIKI_DATA systemctl start fedwiki @@ -388,6 +395,8 @@ function install_fedwiki { function_check add_ddns_domain add_ddns_domain $FEDWIKI_DOMAIN_NAME + fedwiki_remove_bad_links + systemctl enable fedwiki systemctl daemon-reload systemctl start fedwiki