summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--application.rb19
1 files changed, 18 insertions, 1 deletions
diff --git a/application.rb b/application.rb
index 8d0429f..96e564b 100644
--- a/application.rb
+++ b/application.rb
@@ -14,7 +14,24 @@ configure :development do
end
before do
- @version = File.read("VERSION").chomp
+ paths = [
+ "/aa",
+ "/api",
+ "/compound",
+ "/dataset",
+ "/feature",
+ "/model",
+ "/nanoparticle",
+ "/report",
+ "/substance",
+ "/swagger",
+ "/validation"]
+ if paths.include?(request.path)
+ @accept = request.env['HTTP_ACCEPT']
+ response['Content-Type'] = @accept
+ else
+ @version = File.read("VERSION").chomp
+ end
end
not_found do