({ launchId })
| 51 | } |
| 52 | |
| 53 | async bookTrip({ launchId }) { |
| 54 | const userId = this.context.user.id; |
| 55 | const res = await this.store.trips.findOrCreate({ |
| 56 | where: { userId, launchId }, |
| 57 | }); |
| 58 | return res && res.length ? res[0].get() : false; |
| 59 | } |
| 60 | |
| 61 | async cancelTrip({ launchId }) { |
| 62 | const userId = this.context.user.id; |