Fixed typo

- changed deleteable to deletable
pull/5/head
Trivernis 5 years ago
parent 69b47d7d8d
commit 21641cbc20

@ -13,6 +13,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Mocha Tests
- worker initialization error handling
- bearer token authentification for testing purposes
- Added `deletable' field on post
### Removed
@ -33,10 +34,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- graphql schema for denyRequest using the wrong parameters
- sendRequest allowing duplicates
### Added
- Added `deleteable' field on post
## [0.9] - 2019-10-29

@ -286,7 +286,7 @@ type Post {
userVote(userId: ID!): VoteType
"if the post can be deleted by the specified user"
deleteable(userId: ID!): Boolean
deletable(userId: ID!): Boolean
}
"represents a request of any type"

@ -101,7 +101,7 @@ export class Post extends Model<Post> {
* Returns if the post can be deleted by the user with the given id.
* @param userId
*/
public async deleteable({userId}: {userId: number}): Promise<boolean> {
public async deletable({userId}: {userId: number}): Promise<boolean> {
return Number(userId) === Number(this.authorId);
}
}

Loading…
Cancel
Save