Skip to content

Instantly share code, notes, and snippets.

@phoebejaffe
Last active February 14, 2020 05:26
Show Gist options
  • Save phoebejaffe/3da720b62f28a6e55d63480c71893818 to your computer and use it in GitHub Desktop.
Save phoebejaffe/3da720b62f28a6e55d63480c71893818 to your computer and use it in GitHub Desktop.
On OkCupid DoubleTake: Skips users who have their profile set to Monogamous, and alerts "OMG" when it finds users who are set to Non-Monogamous
let alerted = false;
setInterval(() => {
const elem = document.getElementsByClassName('matchprofile-details-text')[0];
if (elem && elem.textContent && elem.textContent.includes('Non-monogamous')) {
if (!alerted) {
alert('omg')
alerted = true;
}
} else if (elem && elem.textContent && elem.textContent.includes('Monogamous')) {
alerted = false;
const passButtons = document.getElementsByClassName('pass-pill-button');
console.log('skip!')
console.log(passButtons.length)
if (passButtons.length === 1) {
passButtons[0].click();
}
} else {
alerted = false;
}
}, 200);
@phoebejaffe
Copy link
Author

To use this:

  1. Open OkCupid in Chrome (probably works in other browser though) and go to the DoubleTake page.
  2. Open the JavaScript Console (Press Cmd-Opt-J on Mac, Ctrl-Opt-J on Windows, or you can use the menus View -> Developer -> JavaScript Console)
  3. Paste the above code into the window, and press enter. Then start liking or skipping people, and it'll take action when it sees someone is either set as Monogamous or Non-Monogamous. It will do nothing for users who don't have the option set.
    To reset, reload the page.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment