Skip to content

Commit

Permalink
Merge pull request #14 from anilanar/ps-0.11
Browse files Browse the repository at this point in the history
update for purescript 0.11
  • Loading branch information
paf31 authored Apr 5, 2017
2 parents 1191132 + 6fc844d commit 8c06790
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 19 deletions.
12 changes: 6 additions & 6 deletions bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@
"url": "git://github.com/purescript-node/purescript-node-http.git"
},
"devDependencies": {
"purescript-console": "^2.0.0"
"purescript-console": "^3.0.0"
},
"dependencies": {
"purescript-maps": "^2.0.0",
"purescript-node-streams": "^2.0.0",
"purescript-node-url": "^2.0.0",
"purescript-options": "^2.0.0",
"purescript-unsafe-coerce": "^2.0.0"
"purescript-maps": "^3.0.0",
"purescript-node-streams": "^3.0.0",
"purescript-node-url": "^3.0.0",
"purescript-options": "^3.0.0",
"purescript-unsafe-coerce": "^3.0.0"
}
}
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
"private": true,
"scripts": {
"clean": "rimraf output && rimraf .pulp-cache",
"build": "jshint src && jscs src && pulp build --censor-lib --strict",
"build": "jshint src && jscs src && pulp build -- --censor-lib --strict",
"test": "pulp build -I test"
},
"devDependencies": {
"jscs": "^3.0.7",
"jshint": "^2.9.4",
"pulp": "^9.0.1",
"purescript-psa": "^0.3.9",
"purescript": "^0.10.1",
"rimraf": "^2.5.4"
"pulp": "^11.0.0",
"purescript": "^0.11.1",
"purescript-psa": "^0.5.0",
"rimraf": "^2.6.1"
}
}
10 changes: 5 additions & 5 deletions src/Node/HTTP.purs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ module Node.HTTP

import Prelude

import Control.Monad.Eff (Eff)
import Control.Monad.Eff (Eff, kind Effect)

import Data.Maybe (Maybe)
import Data.Nullable (Nullable, toNullable)
Expand All @@ -37,16 +37,16 @@ import Node.Stream (Writable, Readable)
import Unsafe.Coerce (unsafeCoerce)

-- | The type of a HTTP server object
foreign import data Server :: *
foreign import data Server :: Type

-- | A HTTP request object
foreign import data Request :: *
foreign import data Request :: Type

-- | A HTTP response object
foreign import data Response :: *
foreign import data Response :: Type

-- | The effect associated with using the HTTP module.
foreign import data HTTP :: !
foreign import data HTTP :: Effect

-- | Create a HTTP server, given a function to be executed when a request is received.
foreign import createServer :: forall eff. (Request -> Response -> Eff (http :: HTTP | eff) Unit) -> Eff (http :: HTTP | eff) Server
Expand Down
4 changes: 2 additions & 2 deletions src/Node/HTTP/Client.purs
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,10 @@ import Node.URL as URL
import Unsafe.Coerce (unsafeCoerce)

-- | A HTTP request object
foreign import data Request :: *
foreign import data Request :: Type

-- | A HTTP response object
foreign import data Response :: *
foreign import data Response :: Type

-- | A HTTP request object
newtype RequestHeaders = RequestHeaders (StrMap String)
Expand Down
2 changes: 1 addition & 1 deletion test/Main.purs
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ testBasic = do
, "</form>"
]
setHeader res "Content-Type" "text/html"
writeString outputStream UTF8 html (pure unit)
_ <- writeString outputStream UTF8 html (pure unit)
end outputStream (pure unit)
"POST" -> void $ pipe inputStream outputStream
_ -> unsafeCrashWith "Unexpected HTTP method"
Expand Down

0 comments on commit 8c06790

Please sign in to comment.