Skip to content

Commit

Permalink
Clean up comments and duplicate variables
Browse files Browse the repository at this point in the history
  • Loading branch information
ianmcorvidae committed Nov 4, 2024
1 parent 0a164b7 commit dc99043
Showing 1 changed file with 1 addition and 10 deletions.
11 changes: 1 addition & 10 deletions src/components/apps/savedLaunch/SavedLaunchListing.js
Original file line number Diff line number Diff line change
Expand Up @@ -211,14 +211,13 @@ function ListSavedLaunches(props) {
queryFn: () => listSavedLaunches({ appId }),
});

// It would be better to have a query that is limited to the selected app only
const {
data: allILs,
error: errorILs,
isFetching: fetchingILs,
} = useQuery(ALL_INSTANT_LAUNCHES_KEY, listFullInstantLaunches);

// probably a "list instant launches by saved launches" or "list instant launches by app" here?

const savedLaunchClickHandler = (event, savedLaunch) => {
var instantLaunch = allILs.instant_launches.find(
(el) => el.quick_launch_id === savedLaunch.id
Expand Down Expand Up @@ -265,7 +264,6 @@ function ListSavedLaunches(props) {
const imgSrc = `${host}/${constants.SAVED_LAUNCH_EMBED_ICON}`;

if (useInstantLaunch && selectedIL?.id) {
const host = getHost();
shareUrl = `${host}${getInstantLaunchPath(selectedIL?.id)}`;
} else {
shareUrl = getShareUrl();
Expand Down Expand Up @@ -422,13 +420,6 @@ function ListSavedLaunches(props) {
</IconButton>
</DialogTitle>
<DialogContent>
{
// Here is where we need to add a toggle for instant launch
// If off, use what's alreay below
// If on:
// if there's an instant launch, update the embed code to use it and show?
// if not, maybe a confirmation button? or should we just create it
}
<FormControlLabel
disabled={!selectedIL}
control={
Expand Down

0 comments on commit dc99043

Please sign in to comment.