diff --git a/webui/src/main/js/trustLists.js b/webui/src/main/js/trustLists.js
index 400b361e..1faf5022 100644
--- a/webui/src/main/js/trustLists.js
+++ b/webui/src/main/js/trustLists.js
@@ -144,6 +144,18 @@ function unsubscribe(user) {
xmlhttp.send("action=unsubscribe&persona=" + user)
}
+function forceUpdate(user) {
+ var xmlhttp = new XMLHttpRequest()
+ xmlhttp.onreadystatechange = function() {
+ if (this.readyState == 4 && this.status == 200) {
+ refreshLists()
+ }
+ }
+ xmlhttp.open("POST","/MuWire/Trust", true)
+ xmlhttp.setRequestHeader('Content-type', 'application/x-www-form-urlencoded');
+ xmlhttp.send("action=subscribe&persona=" + user)
+}
+
function updateDiv(name, list) {
var html = "
| User | Reason | Your Trust | Actions |
"
@@ -208,7 +220,7 @@ function refreshLists() {
}
- var html = "| Name | Trusted | Distrusted | Status | Last Updated | Unsubscribe |
"
+ var html = "| Name | Trusted | Distrusted | Status | Last Updated | Actions |
"
for (var [user, list] of lists) {
html += ""
html += "| " + "" + list.user + " | "
@@ -216,7 +228,9 @@ function refreshLists() {
html += "" + list.distrusted +" | "
html += "" + list.status + " | "
html += "" + list.timestamp + " | "
- html += "" + "Unsubscribe | "
+ html += "" + "Unsubscribe" +
+ " Refresh" +
+ " | "
html += "
"
}
html += "
"