mirror of
https://github.com/IT4Change/Ocelot-Social.git
synced 2025-12-13 07:45:56 +00:00
Merge pull request #1298 from Human-Connection/dependabot/npm_and_yarn/backend/eslint-config-standard-14.0.0
Bump eslint-config-standard from 13.0.1 to 14.0.0 in /backend
This commit is contained in:
commit
af377fd06c
@ -116,7 +116,7 @@
|
||||
"cucumber": "~5.1.0",
|
||||
"eslint": "~6.2.0",
|
||||
"eslint-config-prettier": "~6.1.0",
|
||||
"eslint-config-standard": "~13.0.1",
|
||||
"eslint-config-standard": "~14.0.0",
|
||||
"eslint-plugin-import": "~2.18.2",
|
||||
"eslint-plugin-jest": "~22.15.1",
|
||||
"eslint-plugin-node": "~9.1.0",
|
||||
|
||||
@ -102,27 +102,27 @@ export default class ActivityPub {
|
||||
handleUndoActivity(activity) {
|
||||
debug('inside UNDO')
|
||||
switch (activity.object.type) {
|
||||
case 'Follow':
|
||||
case 'Follow': {
|
||||
const followActivity = activity.object
|
||||
return this.dataSource.undoFollowActivity(followActivity.actor, followActivity.object)
|
||||
case 'Like':
|
||||
}
|
||||
case 'Like': {
|
||||
return this.dataSource.deleteShouted(activity)
|
||||
default:
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
handleCreateActivity(activity) {
|
||||
debug('inside create')
|
||||
switch (activity.object.type) {
|
||||
case 'Article':
|
||||
case 'Note':
|
||||
case 'Note': {
|
||||
const articleObject = activity.object
|
||||
if (articleObject.inReplyTo) {
|
||||
return this.dataSource.createComment(activity)
|
||||
} else {
|
||||
return this.dataSource.createPost(activity)
|
||||
}
|
||||
default:
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -159,13 +159,14 @@ export default class ActivityPub {
|
||||
async handleAcceptActivity(activity) {
|
||||
debug('inside accept')
|
||||
switch (activity.object.type) {
|
||||
case 'Follow':
|
||||
case 'Follow': {
|
||||
const followObject = activity.object
|
||||
const followingCollectionPage = await this.collections.getFollowingCollectionPage(
|
||||
followObject.actor,
|
||||
)
|
||||
followingCollectionPage.orderedItems.push(followObject.object)
|
||||
await this.dataSource.saveFollowingCollectionPage(followingCollectionPage)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -51,7 +51,7 @@ export function createSignature(options) {
|
||||
// verifying
|
||||
export function verifySignature(url, headers) {
|
||||
return new Promise((resolve, reject) => {
|
||||
const signatureHeader = headers['signature'] ? headers['signature'] : headers['Signature']
|
||||
const signatureHeader = headers.signature ? headers.signature : headers.Signature
|
||||
if (!signatureHeader) {
|
||||
debug('No Signature header present!')
|
||||
resolve(false)
|
||||
|
||||
@ -3274,10 +3274,10 @@ eslint-config-prettier@~6.1.0:
|
||||
dependencies:
|
||||
get-stdin "^6.0.0"
|
||||
|
||||
eslint-config-standard@~13.0.1:
|
||||
version "13.0.1"
|
||||
resolved "https://registry.yarnpkg.com/eslint-config-standard/-/eslint-config-standard-13.0.1.tgz#c9c6ffe0cfb8a51535bc5c7ec9f70eafb8c6b2c0"
|
||||
integrity sha512-zLKp4QOgq6JFgRm1dDCVv1Iu0P5uZ4v5Wa4DTOkg2RFMxdCX/9Qf7lz9ezRj2dBRa955cWQF/O/LWEiYWAHbTw==
|
||||
eslint-config-standard@~14.0.0:
|
||||
version "14.0.0"
|
||||
resolved "https://registry.yarnpkg.com/eslint-config-standard/-/eslint-config-standard-14.0.0.tgz#1de7bf5af37542dc6eef879ab7eb5e5e0f830747"
|
||||
integrity sha512-bV6e2LFvJEetrLjVAy4KWPOUsIhPWr040c649MigTPR6yUtaGuOt6CEAyNeez2lRiC+2+vjGWa02byjs25EB3A==
|
||||
|
||||
eslint-import-resolver-node@^0.3.2:
|
||||
version "0.3.2"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user