feat: get breakfast package from API
This commit is contained in:
@@ -75,7 +75,7 @@ function getUniqueRewardIds(rewardIds: string[]) {
|
||||
|
||||
const getAllCachedApiRewards = unstable_cache(
|
||||
async function (token) {
|
||||
const apiResponse = await api.get(api.endpoints.v1.tierRewards, {
|
||||
const apiResponse = await api.get(api.endpoints.v1.Profile.tierRewards, {
|
||||
headers: {
|
||||
Authorization: `Bearer ${token}`,
|
||||
},
|
||||
@@ -194,7 +194,7 @@ export const rewardQueryRouter = router({
|
||||
|
||||
const { limit, cursor } = input
|
||||
|
||||
const apiResponse = await api.get(api.endpoints.v1.rewards, {
|
||||
const apiResponse = await api.get(api.endpoints.v1.Profile.reward, {
|
||||
cache: undefined, // override defaultOptions
|
||||
headers: {
|
||||
Authorization: `Bearer ${ctx.session.token.access_token}`,
|
||||
@@ -393,7 +393,7 @@ export const rewardQueryRouter = router({
|
||||
surprises: contentStackBaseWithProtectedProcedure.query(async ({ ctx }) => {
|
||||
getCurrentRewardCounter.add(1)
|
||||
|
||||
const apiResponse = await api.get(api.endpoints.v1.rewards, {
|
||||
const apiResponse = await api.get(api.endpoints.v1.Profile.reward, {
|
||||
cache: undefined, // override defaultOptions
|
||||
headers: {
|
||||
Authorization: `Bearer ${ctx.session.token.access_token}`,
|
||||
|
||||
Reference in New Issue
Block a user