projects
/
Sone.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Remove bucket and access type from command interface
[Sone.git]
/
src
/
main
/
java
/
net
/
pterodactylus
/
sone
/
web
/
EditAlbumPage.java
diff --git
a/src/main/java/net/pterodactylus/sone/web/EditAlbumPage.java
b/src/main/java/net/pterodactylus/sone/web/EditAlbumPage.java
index
5244bc5
..
5829c8b
100644
(file)
--- a/
src/main/java/net/pterodactylus/sone/web/EditAlbumPage.java
+++ b/
src/main/java/net/pterodactylus/sone/web/EditAlbumPage.java
@@
-1,5
+1,5
@@
/*
/*
- * Sone - EditAlbumPage.java - Copyright © 2011–201
5
David Roden
+ * Sone - EditAlbumPage.java - Copyright © 2011–201
6
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
@@
-48,8
+48,7
@@
public class EditAlbumPage extends SoneTemplatePage {
* {@inheritDoc}
*/
@Override
* {@inheritDoc}
*/
@Override
- protected void processTemplate(FreenetRequest request, TemplateContext templateContext) throws RedirectException {
- super.processTemplate(request, templateContext);
+ protected void handleRequest(FreenetRequest request, TemplateContext templateContext) throws RedirectException {
if (request.getMethod() == Method.POST) {
String albumId = request.getHttpRequest().getPartAsStringFailsafe("album", 36);
Album album = webInterface.getCore().getAlbum(albumId);
if (request.getMethod() == Method.POST) {
String albumId = request.getHttpRequest().getPartAsStringFailsafe("album", 36);
Album album = webInterface.getCore().getAlbum(albumId);
@@
-68,11
+67,6
@@
public class EditAlbumPage extends SoneTemplatePage {
webInterface.getCore().touchConfiguration();
throw new RedirectException("imageBrowser.html?album=" + album.getParent().getId());
}
webInterface.getCore().touchConfiguration();
throw new RedirectException("imageBrowser.html?album=" + album.getParent().getId());
}
- String albumImageId = request.getHttpRequest().getPartAsStringFailsafe("album-image", 36);
- if (webInterface.getCore().getImage(albumImageId, false) == null) {
- albumImageId = null;
- }
- album.modify().setAlbumImage(albumImageId).update();
String title = request.getHttpRequest().getPartAsStringFailsafe("title", 100).trim();
String description = request.getHttpRequest().getPartAsStringFailsafe("description", 1000).trim();
try {
String title = request.getHttpRequest().getPartAsStringFailsafe("title", 100).trim();
String description = request.getHttpRequest().getPartAsStringFailsafe("description", 1000).trim();
try {