diff --git a/Ganeti/HTools/Utils.hs b/Ganeti/HTools/Utils.hs index 45b9d5e522026cdf1448f09f517ce912b16b3102..609185806943fd30ad257fa8a1d77e27e6e891af 100644 --- a/Ganeti/HTools/Utils.hs +++ b/Ganeti/HTools/Utils.hs @@ -157,7 +157,10 @@ annotateResult _ v = v -- | Try to extract a key from a object with better error reporting -- than fromObj tryFromObj :: (J.JSON a) => - String -> [(String, J.JSValue)] -> String -> Result a + String -- ^ Textual "owner" in error messages + -> [(String, J.JSValue)] -- ^ The object array + -> String -- ^ The desired key from the object + -> Result a tryFromObj t o k = annotateResult t (fromObj k o) -- | Small wrapper over readJSON.