mirror of
https://github.com/RoboSats/robosats.git
synced 2025-08-03 01:11:40 +00:00
Remove unused code
This commit is contained in:
@ -14,7 +14,7 @@ const Routes: React.FC = () => {
|
||||
useEffect(() => {
|
||||
if (window.AndroidDataRobosats && garage.currentSlot) {
|
||||
const orderPath = window.AndroidDataRobosats.navigateToPage ?? '';
|
||||
const [coordinator, orderId] = orderPath.replace('#', '/').split('/');
|
||||
const [coordinator, orderId] = orderPath.split('/');
|
||||
window.AndroidDataRobosats = undefined;
|
||||
|
||||
if (orderId && coordinator) {
|
||||
|
@ -55,7 +55,7 @@ const NotificationCard: React.FC<Props> = ({ event, robotHashId, coordinator, se
|
||||
if (slot?.token) {
|
||||
setShow(false);
|
||||
garage.setCurrentSlot(slot.token);
|
||||
navigateToPage(`order/${orderId.replace('#', '/')}`, navigate);
|
||||
navigateToPage(`order/${orderId}`, navigate);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
@ -150,7 +150,7 @@ const NotificationsDrawer = ({
|
||||
if (slot?.token) {
|
||||
setShow(false);
|
||||
garage.setCurrentSlot(slot.token);
|
||||
navigateToPage(`order/${orderId.replace('#', '/')}`, navigate);
|
||||
navigateToPage(`order/${orderId}`, navigate);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
@ -141,7 +141,7 @@ export const AppContextProvider = ({ children }: AppContextProviderProps): React
|
||||
newPage,
|
||||
navigate,
|
||||
) => {
|
||||
const pathPage: Page | string = newPage.replace('#', '/').split('/')[0];
|
||||
const pathPage: Page | string = newPage.split('/')[0];
|
||||
if (isPage(pathPage)) {
|
||||
setPage(pathPage);
|
||||
navigate(`/${newPage}`);
|
||||
|
Reference in New Issue
Block a user