packages feed

rest-gen 0.15.0.1 → 0.15.0.2

raw patch · 3 files changed

+13/−4 lines, 3 filesdep ~json-schemadep ~textPVP ok

version bump matches the API change (PVP)

Dependency ranges changed: json-schema, text

API changes (from Hackage documentation)

Files

CHANGELOG.md view
@@ -1,5 +1,9 @@ # Changelog +#### 0.15.0.2++* Allow `json-schema 0.7.*`+ #### 0.15.0.1  * JavaScript/node.js: Fixed error handling for `ECONNREFUSED` and other "top level" errors.
rest-gen.cabal view
@@ -1,5 +1,5 @@ name:                rest-gen-version:             0.15.0.1+version:             0.15.0.2 description:         Documentation and client generation from rest definition. synopsis:            Documentation and client generation from rest definition. maintainer:          code@silk.co@@ -60,7 +60,7 @@     , haskell-src-exts >= 1.15.0 && < 1.16.0     , hslogger >= 1.1 && < 1.3     , hxt >= 9.2 && < 9.4-    , json-schema == 0.6.*+    , json-schema >= 0.6 && < 0.8     , pretty >= 1.0 && < 1.2     , process >= 1.0 && < 1.3     , rest-core >= 0.31 && < 0.33
src/Rest/Gen/Base/JSON.hs view
@@ -1,4 +1,7 @@-{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE+    CPP+  , OverloadedStrings+  #-} module Rest.Gen.Base.JSON (showExample) where  import Data.Aeson ((.=))@@ -23,9 +26,11 @@       Value _      -> A.String "value"       Boolean      -> A.Bool True       Number b     -> A.Number . boundExample $ b-      Null         -> A.Null       Any          -> A.String "<value>"       Constant v   -> v+#if !MIN_VERSION_json_schema(0,7,0)+      Null         -> A.Null+#endif  boundExample :: Num a => Bound -> a boundExample b = fromIntegral $ fromMaybe 0 (maybe (lower b) Just (upper b))