Skip to content

Commit

Permalink
fix: linting fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Maciej Makowski committed Jul 25, 2024
1 parent 1266a6c commit 92568e0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions example/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const App: React.FC = () => {
const [gain, setGain] = useState<number>(1.0);
const [frequency, setFrequency] = useState<number>(440);
const [detune, setDetune] = useState<number>(0);

const audioContextRef = useRef<AudioContext | null>(null);
const oscillatorRef = useRef<Oscillator | null>(null);
const gainRef = useRef<Gain | null>(null);
Expand All @@ -29,7 +29,7 @@ const App: React.FC = () => {

gainRef.current = audioContextRef.current.createGain();
gainRef.current.gain = gain;

if (Platform.OS === 'android') {
const destination = audioContextRef.current.destination;
oscillatorRef.current.connect(destination!);
Expand Down Expand Up @@ -59,7 +59,7 @@ const App: React.FC = () => {
oscillatorRef.current.detune = newValue;
}
};

useEffect(() => {
return () => {
oscillatorRef.current?.stop(0);
Expand Down

0 comments on commit 92568e0

Please sign in to comment.