Commit 54e2e82e authored by Damien Gerard's avatar Damien Gerard

Fixed potential empty path in Swagger description

parent fcb83f89
...@@ -362,7 +362,7 @@ Swagger::install(Rest::Router& router) { ...@@ -362,7 +362,7 @@ Swagger::install(Rest::Router& router) {
: value(value) : value(value)
, trailingSlashValue(value) , trailingSlashValue(value)
{ {
if (trailingSlashValue.back() != '/') if (trailingSlashValue.empty() || trailingSlashValue.back() != '/')
trailingSlashValue += '/'; trailingSlashValue += '/';
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment