Skip to content

Commit

Permalink
check /s/ url
Browse files Browse the repository at this point in the history
  • Loading branch information
claromes committed Jan 12, 2024
1 parent 686c000 commit 38102bc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions background.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ chrome.tabs.onUpdated.addListener(function (tabId, changeInfo, tab) {
if (regexProfile) {
const handleProfile = tab.url.split("/")[3];

// Ignore post, reel, TV and explore URLs
if (handleProfile !== 'p' && handleProfile !== 'reel' && handleProfile !== 'tv' && handleProfile !== 'explore') {
// Ignore post, story, reel, TV and explore URLs
if (handleProfile !== 'p' && handleProfile !== 's' && handleProfile !== 'reel' && handleProfile !== 'tv' && handleProfile !== 'explore') {
let redirectUrl = `${BaseUrl}${Profile}${handleProfile}`;

chrome.tabs.update(tabId, { url: redirectUrl });
Expand Down Expand Up @@ -88,7 +88,7 @@ chrome.tabs.onUpdated.addListener(function (tabId, changeInfo, tab) {
const regexTags = /^https:\/\/www\.instagram\.com\/explore\/tags\/([^/]+)/;
const matchTags = tab.url.match(regexTags);

if (matchTags && BaseUrl.includes('picuki')) {
if (matchTags) {
const tagName = matchTags[1];
const redirectUrlTags = `${BaseUrl}/tag/${tagName}`;

Expand Down

0 comments on commit 38102bc

Please sign in to comment.