summaryrefslogtreecommitdiff
path: root/src/Language/GraphQL/Execute
diff options
context:
space:
mode:
authorEugen Wissner <belka@caraus.de>2021-09-04 07:27:51 +0200
committerEugen Wissner <belka@caraus.de>2021-09-04 07:27:51 +0200
commit7444895a58b4a92c8972cc8a7fda690ee0d3b955 (patch)
tree1117ad88f0a92cd0e01776a8a8ad9a2a5563b2df /src/Language/GraphQL/Execute
parentde4f69ab0312edfd7c0deb033aa6103442eb3ec8 (diff)
downloadgraphql-7444895a58b4a92c8972cc8a7fda690ee0d3b955.tar.gz
Remove unused (and not exposed) Execute.Internal
Diffstat (limited to 'src/Language/GraphQL/Execute')
-rw-r--r--src/Language/GraphQL/Execute/Internal.hs31
1 files changed, 0 insertions, 31 deletions
diff --git a/src/Language/GraphQL/Execute/Internal.hs b/src/Language/GraphQL/Execute/Internal.hs
deleted file mode 100644
index 046db45..0000000
--- a/src/Language/GraphQL/Execute/Internal.hs
+++ /dev/null
@@ -1,31 +0,0 @@
-{- This Source Code Form is subject to the terms of the Mozilla Public License,
- v. 2.0. If a copy of the MPL was not distributed with this file, You can
- obtain one at https://mozilla.org/MPL/2.0/. -}
-
-{-# LANGUAGE DuplicateRecordFields #-}
-{-# LANGUAGE ExplicitForAll #-}
-{-# LANGUAGE NamedFieldPuns #-}
-
-module Language.GraphQL.Execute.Internal
- ( addError
- , singleError
- ) where
-
-import Control.Monad.Trans.State (modify)
-import Control.Monad.Catch (MonadCatch)
-import Data.Sequence ((|>))
-import qualified Data.Text as Text
-import qualified Language.GraphQL.AST as Full
-import Language.GraphQL.Error (CollectErrsT, Error(..), Resolution(..))
-import Prelude hiding (null)
-
-addError :: MonadCatch m => forall a. a -> Error -> CollectErrsT m a
-addError returnValue error' = modify appender >> pure returnValue
- where
- appender :: Resolution m -> Resolution m
- appender resolution@Resolution{ errors } = resolution
- { errors = errors |> error'
- }
-
-singleError :: [Full.Location] -> String -> Error
-singleError errorLocations message = Error (Text.pack message) errorLocations []