1. Atlassian
  2. Project: Atlassian
  3. developer-toolbox

Commits

Rich Manalang  committed 335b1bd

AMPS-873 Dev toolbar is broken when fastev is disabled -- this fixes this issue

  • Participants
  • Parent commits 7684d62
  • Branches master

Comments (0)

Files changed (1)

File src/main/java/com/atlassian/devrel/servlet/ToolbarServlet.java

View file
         context.put("navBarMenuItems", webInterfaceManager.getDisplayableItems("dev-toolbar-menu", condition));
         context.put("app", applicationProperties);
         context.put("sdkVersion", System.getProperty("atlassian.sdk.version", "3.7 or earlier"));
-        context.put("fastDevVersion",pluginAccessor.getPlugin("com.atlassian.labs.fastdev-plugin").getPluginInformation().getVersion());
         context.put("devToolboxVersion",pluginAccessor.getPlugin("com.atlassian.devrel.developer-toolbox-plugin").getPluginInformation().getVersion());
 
+        if (pluginAccessor.isPluginEnabled("com.atlassian.labs.fastdev-plugin")){
+            context.put("fastDevVersion",pluginAccessor.getPlugin("com.atlassian.labs.fastdev-plugin").getPluginInformation().getVersion());
+        } else {
+            context.put("fastDevVersion", "disabled");
+        }
+
         resp.setContentType("text/html;charset=utf-8");
         renderer.render(TOOLBAR_TEMPLATE, context, resp.getWriter());
     }