Show the “create Sone” page in the menu if we’re auto-logged in.
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Tue, 25 Jan 2011 08:13:55 +0000 (09:13 +0100)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Tue, 25 Jan 2011 08:13:55 +0000 (09:13 +0100)
src/main/java/net/pterodactylus/sone/web/CreateSonePage.java

index c33974b..cc40320 100644 (file)
@@ -129,7 +129,7 @@ public class CreateSonePage extends SoneTemplatePage {
         */
        @Override
        public boolean isEnabled(ToadletContext toadletContext) {
-               return getCurrentSone(toadletContext, false) == null;
+               return (getCurrentSone(toadletContext, false) == null) || (webInterface.getCore().getLocalSones().size() == 1);
        }
 
 }