@waline/vercel 1.19.2 → 1.19.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@waline/vercel",
3
- "version": "1.19.2",
3
+ "version": "1.19.3",
4
4
  "description": "vercel server for waline comment system",
5
5
  "keywords": [
6
6
  "waline",
@@ -573,7 +573,10 @@ module.exports = class extends BaseRest {
573
573
  parentComment = await this.modelInstance.select({ objectId: pid });
574
574
  parentComment = parentComment[0];
575
575
  if (parentComment.user_id) {
576
- parentUser = await this.model('User').select({
576
+ parentUser = await this.service(
577
+ `storage/${this.config('storage')}`,
578
+ 'User'
579
+ ).select({
577
580
  objectId: parentComment.user_id,
578
581
  });
579
582
  parentUser = parentUser[0];
@@ -665,7 +668,10 @@ module.exports = class extends BaseRest {
665
668
  let cmtUser;
666
669
 
667
670
  if (newData.user_id) {
668
- cmtUser = await this.model('User').select({
671
+ cmtUser = await this.service(
672
+ `storage/${this.config('storage')}`,
673
+ 'User'
674
+ ).select({
669
675
  objectId: newData.user_id,
670
676
  });
671
677
  cmtUser = cmtUser[0];
@@ -680,7 +686,10 @@ module.exports = class extends BaseRest {
680
686
  let pUser;
681
687
 
682
688
  if (pComment.user_id) {
683
- pUser = await this.model('User').select({
689
+ pUser = await this.service(
690
+ `storage/${this.config('storage')}`,
691
+ 'User'
692
+ ).select({
684
693
  objectId: pComment.user_id,
685
694
  });
686
695
  pUser = pUser[0];