You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I just fixed a mistake in our code that would have been nice to catch in the library: if you add the same name for a json schema twice in the same swagger document, it's almost certainly a mistake and should trigger an error.
Example (not tested):
instance ToSchema T1 where
declareNamedSchema _ = pure $ NamedSchema (Just "T1") mempty
instance ToSchema T2 where
declareNamedSchema _ = pure $ NamedSchema (Just "T1") mempty
The typo in T2 causes the two generated schemas to be stored under the same name, and one of them being overwritten. I think this should trigger an error.
The text was updated successfully, but these errors were encountered:
I just fixed a mistake in our code that would have been nice to catch in the library: if you add the same name for a json schema twice in the same swagger document, it's almost certainly a mistake and should trigger an error.
Example (not tested):
The typo in T2 causes the two generated schemas to be stored under the same name, and one of them being overwritten. I think this should trigger an error.
The text was updated successfully, but these errors were encountered: