Skip to content

Commit

Permalink
move inventory file out of utils bc evolved beyond just getInventory()
Browse files Browse the repository at this point in the history
  • Loading branch information
kibagateaux committed Dec 11, 2023
1 parent c44ded9 commit 813ade4
Show file tree
Hide file tree
Showing 14 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/app/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { getIconForWidget } from 'utils/rendering';
import { AvatarViewer, WidgetIcon } from 'components/index';
import DefaultAvatar from 'assets/avatars/happy-ghost';
import WidgetContainer from 'components/home/WidgetContainer';
import { getActivityData } from 'utils/inventory/android-health-connect';
import { getActivityData } from 'inventory/android-health-connect';

const HomeScreen = () => {
const { player } = useAuth();
Expand Down
2 changes: 1 addition & 1 deletion src/hooks/useInventory.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { useState, useMemo } from 'react';

import { InventoryItem } from 'types/GameMechanics';
import utils from 'utils/inventory';
import utils from 'inventory';
import { useAuth } from 'contexts/AuthContext';

// interface UseInventoryProps {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {
iosInventory,
androidInventory,
// allInventoryItems,
} from 'utils/inventory';
} from 'inventory';
import maliksMajik from '../maliks-majik';

// TODO figure out how to make generalized mock for NFC
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 4 additions & 0 deletions src/utils/inventory/spotify.ts → src/inventory/spotify.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,10 @@ const item: InventoryItem = {
canDo: async (status: ItemStatus) => (status === 'equipped' ? true : false),
do: async () => {
console.log('Spotify:Ability:ShareProfile');
track(SHARE_CONTENT, {
ability: ABILITY_SHARE_PROFILE,
activityType: 'initiated',
});
const pid = await getPlayerId();
console.log('Spotify:Ability:ShareProfile:pid', pid);
if (!pid) return async () => false;
Expand Down

0 comments on commit 813ade4

Please sign in to comment.