targetprocess-rest-api
Advanced tools
Comparing version
@@ -104,3 +104,6 @@ "use strict"; | ||
if (!res.ok) { | ||
throw Error(res.statusText); | ||
throw { | ||
statusCode: res.status, | ||
message: res.statusText | ||
}; | ||
} | ||
@@ -107,0 +110,0 @@ return [2 /*return*/, res.json()]; |
{ | ||
"name": "targetprocess-rest-api", | ||
"version": "0.2.0", | ||
"version": "0.2.1", | ||
"description": "TypeScript API wrapper for Targetprocess", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -32,4 +32,15 @@ # targetprocess | ||
### Errors | ||
`getUserStory`, `getTask`, `getBug` and `addTime` can all throw an error with the following format: | ||
```typescript | ||
{ | ||
statusCode: number; | ||
message: string; | ||
} | ||
``` | ||
## License | ||
Made with :sparkling_heart: by [NewOrbit](https://www.neworbit.co.uk/) in Oxfordshire, and licensed under the [MIT Licence](LICENCE) |
9284
3.54%126
2.44%46
31.43%