Skip to content
Snippets Groups Projects
Commit 91d1ea5b authored by Akshay Mankar's avatar Akshay Mankar
Browse files

GetState: Fix existence check

parent 94e1cf69
No related branches found
No related tags found
No related merge requests found
# Revision history for terraform-http-backend-pass # Revision history for terraform-http-backend-pass
## Unreleased changes
* GetState: Fix existence check.
## 0.1.0.0 -- 2021-02-28 ## 0.1.0.0 -- 2021-02-28
* First version. Released on an unsuspecting world. * First version. Released on an unsuspecting world.
...@@ -51,7 +51,8 @@ instance (Monad m, MonadIO m) => MonadPass (AppT m) where ...@@ -51,7 +51,8 @@ instance (Monad m, MonadIO m) => MonadPass (AppT m) where
Shelly.run_ "pass" ["rm", name] Shelly.run_ "pass" ["rm", name]
exists name = do exists name = do
Env {..} <- ask Env {..} <- ask
liftIO $ doesFileExist (directory <> "/" <> Text.unpack name) let path = directory <> "/" <> Text.unpack name <> ".gpg"
liftIO $ doesFileExist path
runAppT :: Env -> AppT m a -> m a runAppT :: Env -> AppT m a -> m a
runAppT env (AppT r) = runReaderT r env runAppT env (AppT r) = runReaderT r env
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment