Make sure to pluralized object names in the List method as listed in the
[arvados.git] / app / controllers / orvos / v1 / schema_controller.rb
index 11465a74675e684af72a9af426a121ab7039864e..673aca47bdc1e453e1212fcd35ccfaf837316144 100644 (file)
@@ -101,15 +101,15 @@ class Orvos::V1::SchemaController < ApplicationController
             }
           end
         end
-        discovery[:schemas][k.to_s + 'List'] = {
+        discovery[:schemas][k.to_s.pluralize + 'List'] = {
           id: k.to_s,
           description: k.to_s,
           type: "object",
           properties: {
             kind: {
               type: "string",
-              description: "Object type. Always orvos##{k.to_s.camelcase(:lower)}List.",
-              default: "orvos##{k.to_s.camelcase(:lower)}List"
+              description: "Object type. Always orvos##{k.to_s.pluralize.camelcase(:lower)}List.",
+              default: "orvos##{k.to_s.pluralize.camelcase(:lower)}List"
             },
             etag: {
               type: "string",