projects
/
Sone.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Remove possibility to create Sones from sone provider interface.
[Sone.git]
/
src
/
main
/
java
/
net
/
pterodactylus
/
sone
/
web
/
ajax
/
UntrustAjaxPage.java
diff --git
a/src/main/java/net/pterodactylus/sone/web/ajax/UntrustAjaxPage.java
b/src/main/java/net/pterodactylus/sone/web/ajax/UntrustAjaxPage.java
index
932be6c
..
70e1448
100644
(file)
--- a/
src/main/java/net/pterodactylus/sone/web/ajax/UntrustAjaxPage.java
+++ b/
src/main/java/net/pterodactylus/sone/web/ajax/UntrustAjaxPage.java
@@
-1,5
+1,5
@@
/*
/*
- * Sone - UntrustAjaxPage.java - Copyright © 2011–201
2
David Roden
+ * Sone - UntrustAjaxPage.java - Copyright © 2011–201
3
David Roden
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@
-19,7
+19,6
@@
package net.pterodactylus.sone.web.ajax;
import net.pterodactylus.sone.core.Core;
import net.pterodactylus.sone.data.Sone;
import net.pterodactylus.sone.core.Core;
import net.pterodactylus.sone.data.Sone;
-import net.pterodactylus.sone.freenet.wot.Trust;
import net.pterodactylus.sone.web.WebInterface;
import net.pterodactylus.sone.web.page.FreenetRequest;
import net.pterodactylus.util.json.JsonObject;
import net.pterodactylus.sone.web.WebInterface;
import net.pterodactylus.sone.web.page.FreenetRequest;
import net.pterodactylus.util.json.JsonObject;
@@
-52,16
+51,12
@@
public class UntrustAjaxPage extends JsonPage {
return createErrorJsonObject("auth-required");
}
String soneId = request.getHttpRequest().getParam("sone");
return createErrorJsonObject("auth-required");
}
String soneId = request.getHttpRequest().getParam("sone");
- Sone sone = webInterface.getCore().getSone(soneId
, false
);
+ Sone sone = webInterface.getCore().getSone(soneId);
if (sone == null) {
return createErrorJsonObject("invalid-sone-id");
}
webInterface.getCore().untrustSone(currentSone, sone);
if (sone == null) {
return createErrorJsonObject("invalid-sone-id");
}
webInterface.getCore().untrustSone(currentSone, sone);
- Trust trust = webInterface.getCore().getTrust(currentSone, sone);
- if (trust == null) {
- return createErrorJsonObject("wot-plugin");
- }
- return createSuccessJsonObject().put("trustValue", trust.getExplicit());
+ return createSuccessJsonObject().put("trustValue", (String) null);
}
}
}
}