mirror of
https://github.com/Sendouc/sendou.ink.git
synced 2026-09-14 07:06:14 -05:00
Ignore search params in RAMP
This commit is contained in:
@@ -15,8 +15,6 @@ export const Ramp = () => {
|
||||
const [rampComponentLoaded, setRampComponentLoaded] = useState(false);
|
||||
const location = useLocation();
|
||||
|
||||
const asPath = `${location.pathname}${location.search}`;
|
||||
|
||||
useEffect(() => {
|
||||
if (!PUBLISHER_ID || !WEBSITE_ID) {
|
||||
logger.info("RAMP: Missing Publisher Id or Website Id");
|
||||
@@ -43,10 +41,10 @@ export const Ramp = () => {
|
||||
// Cleanup function to handle component unmount and updating page state
|
||||
return () => {
|
||||
window.ramp.que.push(() => {
|
||||
window.ramp.spaNewPage(asPath);
|
||||
window.ramp.spaNewPage(location.pathname);
|
||||
});
|
||||
};
|
||||
}, [rampComponentLoaded, asPath]);
|
||||
}, [rampComponentLoaded, location.pathname]);
|
||||
|
||||
return null;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user