@@ -911,17 +911,13 @@ protected SortedSet<String> getRequestedProjects(
911
911
return projectNames ;
912
912
}
913
913
914
- /**
915
- * Use a project determined directly from the URL
916
- */
914
+ // Use a project determined directly from the URL
917
915
if (getProject () != null && getProject ().isIndexed ()) {
918
916
projectNames .add (getProject ().getName ());
919
917
return projectNames ;
920
918
}
921
919
922
- /**
923
- * Use a project if the application has only single project.
924
- */
920
+ // Use a project if there is just a single project.
925
921
if (projects .size () == 1 ) {
926
922
Project p = projects .get (0 );
927
923
if (p .isIndexed () && authFramework .isAllowed (req , p )) {
@@ -930,9 +926,7 @@ protected SortedSet<String> getRequestedProjects(
930
926
return projectNames ;
931
927
}
932
928
933
- /**
934
- * Add all projects which match the project parameter name values
935
- */
929
+ // Add all projects which match the project parameter name values/
936
930
List <String > names = getParamVals (projectParamName );
937
931
for (String projectName : names ) {
938
932
Project project = Project .getByName (projectName );
@@ -941,9 +935,7 @@ protected SortedSet<String> getRequestedProjects(
941
935
}
942
936
}
943
937
944
- /**
945
- * Add all projects which are part of a group that matches the group parameter name
946
- */
938
+ // Add all projects which are part of a group that matches the group parameter name.
947
939
names = getParamVals (groupParamName );
948
940
for (String groupName : names ) {
949
941
Group group = Group .getByName (groupName );
@@ -956,6 +948,7 @@ protected SortedSet<String> getRequestedProjects(
956
948
}
957
949
}
958
950
951
+ // Add projects based on cookie.
959
952
if (projectNames .isEmpty ()) {
960
953
List <String > cookies = getCookieVals (cookieName );
961
954
for (String s : cookies ) {
@@ -966,6 +959,7 @@ protected SortedSet<String> getRequestedProjects(
966
959
}
967
960
}
968
961
962
+ // Add default projects.
969
963
if (projectNames .isEmpty ()) {
970
964
Set <Project > defaultProjects = env .getDefaultProjects ();
971
965
if (defaultProjects != null ) {
0 commit comments