diff options
-rw-r--r-- | README.md | 6 | ||||
-rw-r--r-- | server/lib/activitypub/process/process-undo.ts | 10 |
2 files changed, 7 insertions, 9 deletions
@@ -49,7 +49,7 @@ Be part of a network of multiple small federated, interoperable video hosting pr | |||
49 | <img alt="test suite status" src="https://github.com/Chocobozzz/PeerTube/workflows/Test%20Suite/badge.svg" /> | 49 | <img alt="test suite status" src="https://github.com/Chocobozzz/PeerTube/workflows/Test%20Suite/badge.svg" /> |
50 | </a> | 50 | </a> |
51 | 51 | ||
52 | <a href="http://standardjs.com/"> | 52 | <a href="https://standardjs.com/"> |
53 | <img src="https://img.shields.io/badge/code%20style-standard-brightgreen.svg" alt="JavaScript Style Guide" /> | 53 | <img src="https://img.shields.io/badge/code%20style-standard-brightgreen.svg" alt="JavaScript Style Guide" /> |
54 | </a> | 54 | </a> |
55 | </p> | 55 | </p> |
@@ -58,7 +58,7 @@ Be part of a network of multiple small federated, interoperable video hosting pr | |||
58 | 58 | ||
59 | <p align="center"> | 59 | <p align="center"> |
60 | <a href="https://framatube.org/videos/watch/217eefeb-883d-45be-b7fc-a788ad8507d3"> | 60 | <a href="https://framatube.org/videos/watch/217eefeb-883d-45be-b7fc-a788ad8507d3"> |
61 | <img src="http://lutim.cpy.re/9CLXh0Ys.png" alt="screenshot" /> | 61 | <img src="https://lutim.cpy.re/9CLXh0Ys.png" alt="screenshot" /> |
62 | </a> | 62 | </a> |
63 | </p> | 63 | </p> |
64 | 64 | ||
@@ -190,4 +190,4 @@ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |||
190 | GNU Affero General Public License for more details. | 190 | GNU Affero General Public License for more details. |
191 | 191 | ||
192 | You should have received a copy of the GNU Affero General Public License | 192 | You should have received a copy of the GNU Affero General Public License |
193 | along with this program. If not, see <http://www.gnu.org/licenses/>. | 193 | along with this program. If not, see <https://www.gnu.org/licenses/>. |
diff --git a/server/lib/activitypub/process/process-undo.ts b/server/lib/activitypub/process/process-undo.ts index caf672cd6..e520c2f0d 100644 --- a/server/lib/activitypub/process/process-undo.ts +++ b/server/lib/activitypub/process/process-undo.ts | |||
@@ -6,12 +6,12 @@ import { sequelizeTypescript } from '../../../initializers/database' | |||
6 | import { AccountVideoRateModel } from '../../../models/account/account-video-rate' | 6 | import { AccountVideoRateModel } from '../../../models/account/account-video-rate' |
7 | import { ActorModel } from '../../../models/activitypub/actor' | 7 | import { ActorModel } from '../../../models/activitypub/actor' |
8 | import { ActorFollowModel } from '../../../models/activitypub/actor-follow' | 8 | import { ActorFollowModel } from '../../../models/activitypub/actor-follow' |
9 | import { forwardVideoRelatedActivity } from '../send/utils' | ||
10 | import { getOrCreateVideoAndAccountAndChannel } from '../videos' | ||
11 | import { VideoShareModel } from '../../../models/video/video-share' | ||
12 | import { VideoRedundancyModel } from '../../../models/redundancy/video-redundancy' | 9 | import { VideoRedundancyModel } from '../../../models/redundancy/video-redundancy' |
10 | import { VideoShareModel } from '../../../models/video/video-share' | ||
13 | import { APProcessorOptions } from '../../../types/activitypub-processor.model' | 11 | import { APProcessorOptions } from '../../../types/activitypub-processor.model' |
14 | import { MActorSignature } from '../../../types/models' | 12 | import { MActorSignature } from '../../../types/models' |
13 | import { forwardVideoRelatedActivity } from '../send/utils' | ||
14 | import { getOrCreateVideoAndAccountAndChannel } from '../videos' | ||
15 | 15 | ||
16 | async function processUndoActivity (options: APProcessorOptions<ActivityUndo>) { | 16 | async function processUndoActivity (options: APProcessorOptions<ActivityUndo>) { |
17 | const { activity, byActor } = options | 17 | const { activity, byActor } = options |
@@ -22,9 +22,7 @@ async function processUndoActivity (options: APProcessorOptions<ActivityUndo>) { | |||
22 | } | 22 | } |
23 | 23 | ||
24 | if (activityToUndo.type === 'Create') { | 24 | if (activityToUndo.type === 'Create') { |
25 | if (activityToUndo.object.type === 'Dislike') { | 25 | if (activityToUndo.object.type === 'CacheFile') { |
26 | return retryTransactionWrapper(processUndoDislike, byActor, activity) | ||
27 | } else if (activityToUndo.object.type === 'CacheFile') { | ||
28 | return retryTransactionWrapper(processUndoCacheFile, byActor, activity) | 26 | return retryTransactionWrapper(processUndoCacheFile, byActor, activity) |
29 | } | 27 | } |
30 | } | 28 | } |