From c4072f051c9f0b25cced2643a2972ab2001ea7be Mon Sep 17 00:00:00 2001 From: srosse <none@none> Date: Thu, 20 Nov 2014 09:40:29 +0100 Subject: [PATCH] OO-1321: launch only launchable resource --- .../repository/ui/author/AuthorListController.java | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/main/java/org/olat/repository/ui/author/AuthorListController.java b/src/main/java/org/olat/repository/ui/author/AuthorListController.java index 71b5e7ca6c4..54d1efd2339 100644 --- a/src/main/java/org/olat/repository/ui/author/AuthorListController.java +++ b/src/main/java/org/olat/repository/ui/author/AuthorListController.java @@ -760,8 +760,16 @@ public class AuthorListController extends FormBasicController implements Activat NewControllerFactory.getInstance().launch(businessPath, ureq, getWindowControl()); } - private void launchEditDescription(UserRequest ureq, RepositoryEntryRef ref) { - String businessPath = "[RepositoryEntry:" + ref.getKey() + "][EditDescription:0]"; + private void launchEditDescription(UserRequest ureq, RepositoryEntry re) { + RepositoryHandler handler = repositoryHandlerFactory.getRepositoryHandler(re); + if(handler != null && handler.supportsLaunch()) { + String businessPath = "[RepositoryEntry:" + re.getKey() + "][EditDescription:0]"; + NewControllerFactory.getInstance().launch(businessPath, ureq, getWindowControl()); + } + } + + private void launchEditDescription(UserRequest ureq, RepositoryEntryRef re) { + String businessPath = "[RepositoryEntry:" + re.getKey() + "][EditDescription:0]"; NewControllerFactory.getInstance().launch(businessPath, ureq, getWindowControl()); } -- GitLab