Reading-eScience-Centre / ncwms

ncWMS - A Web Map Service for displaying environmental data over the web
Other
62 stars 30 forks source link

fix the null alias bug #81

Closed ZihengSun closed 3 years ago

ZihengSun commented 3 years ago

In the administrator interface, people can save a dynamic service with no value for alias (I am sure that should be a bug too). That will make all the other dynamic services inaccessible. All the requests will return "the layer XXX is not found". This fix will solve that problem.

guygriffiths commented 3 years ago

This check needs to be !testDynamicService.getAlias().isEmpty() and there should be a couple of additional checks in NcwmsAdminServlet to make sure that empty aliases don't get through in the first place. The PR also needs to go to develop, not master. I'm happy to make these changes, or you can put in another PR, whatever you prefer.