We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9a5f81b commit 0a938cdCopy full SHA for 0a938cd
apps/server/src/services/PostApiService/index.mts
@@ -57,6 +57,10 @@ export class PostApiService implements Service {
57
ip,
58
})
59
60
+ if (!post) {
61
+ throw new NotFoundError('Not found post when create post')
62
+ }
63
+
64
if (series_id && !data.is_temp) {
65
await this.seriesService.appendToSeries(series_id, post.id)
66
}
@@ -75,6 +79,10 @@ export class PostApiService implements Service {
75
79
76
80
77
81
82
83
+ throw new NotFoundError('Not found post when edit post')
84
85
78
86
const prevSeriesPost = await this.db.seriesPost.findFirst({
87
where: {
88
fk_post_id: post.id,
0 commit comments