From: David ‘Bombe’ Roden Date: Fri, 5 Jul 2013 18:59:54 +0000 (+0200) Subject: Add a static import for slightly more readable code. X-Git-Tag: 0.8.6^2~2 X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=c9a7798a840281a865f8b776d1518563a55485d8;p=Sone.git Add a static import for slightly more readable code. --- diff --git a/src/main/java/net/pterodactylus/sone/web/ImageBrowserPage.java b/src/main/java/net/pterodactylus/sone/web/ImageBrowserPage.java index 37ab701..9dec1dc 100644 --- a/src/main/java/net/pterodactylus/sone/web/ImageBrowserPage.java +++ b/src/main/java/net/pterodactylus/sone/web/ImageBrowserPage.java @@ -19,6 +19,8 @@ package net.pterodactylus.sone.web; import static net.pterodactylus.sone.data.Album.FLATTENER; import static net.pterodactylus.sone.data.Album.NOT_EMPTY; +import static net.pterodactylus.sone.data.Album.TITLE_COMPARATOR; + import java.net.URI; import java.util.ArrayList; import java.util.Collections; @@ -94,7 +96,7 @@ public class ImageBrowserPage extends SoneTemplatePage { for (Sone sone : webInterface.getCore().getSones()) { albums.addAll(FluentIterable.from(sone.getAlbums()).transformAndConcat(FLATTENER).filter(NOT_EMPTY).toList()); } - Collections.sort(albums, Album.TITLE_COMPARATOR); + Collections.sort(albums, TITLE_COMPARATOR); Pagination albumPagination = new Pagination(albums, 12).setPage(Numbers.safeParseInteger(request.getHttpRequest().getParam("page"), 0)); templateContext.set("albumPagination", albumPagination); templateContext.set("albums", albumPagination.getItems());