*hello could you help me I have a problem this is the error:
Uncaught ReferenceError: process is not defined
at Object.4043 (:2:13168)
at r (:2:306599)
at Object.8048 (:2:9496)
at r (:2:306599)
at Object.8641 (:2:1379)
at r (:2:306599)
at :2:315627
at :2:324225
at :2:324229
at HTMLIFrameElement.e.onload (index.js:1:1)
*and this:
POST https://i0eflwmjf9be.usemoralis.com:2053/server/functions/getMyList 400
*and this:
RESTController.js:438 Uncaught (in promise) Error: Cannot read properties of undefined (reading 'attributes')
at handleError (RESTController.js:438:1)
at async fetchMyList (Home.js:25:1)
handleError @ RESTController.js:438
await in handleError (async)
(anonymous) @ Home.js:32
invokePassiveEffectCreate @ react-dom.development.js:23487
callCallback @ react-dom.development.js:3945
invokeGuardedCallbackDev @ react-dom.development.js:3994
invokeGuardedCallback @ react-dom.development.js:4056
flushPassiveEffectsImpl @ react-dom.development.js:23574
unstable_runWithPriority @ scheduler.development.js:468
runWithPriority$1 @ react-dom.development.js:11276
flushPassiveEffects @ react-dom.development.js:23447
(anonymous) @ react-dom.development.js:23324
workLoop @ scheduler.development.js:417
flushWork @ scheduler.development.js:390
performWorkUntilDeadline @ scheduler.development.js:157
my code is:
import React,{useEffect, useState} from âreactâ;
import { Link, useParams } from âreact-router-domâ;
import â./Home.cssâ;
import { Logo } from ââŚ/images/Netflixâ;
import { Button, ConnectButton,Icon, Modal, Tab, TabList, useNotification } from âweb3uikitâ
import {movies} from ââŚ/helpers/libraryâ
import { useMoralis } from âreact-moralisâ;
import { message } from âantdâ;
const Home = () => {
const[visible, setVisible] = useState(false)
const[selectMovie, setSelectMovie] = useState()
const[myMovies, setMyMovies] = useState()
const{isAuthenticated, Moralis, account} = useMoralis()
const dispatch = useNotification()
useEffect(()=>{
async function fetchMyList(){
const theList = await Moralis.Cloud.run("getMyList", {addrs: account})
const filterA = movies.filter(function(e){
return theList.indexOf(e.Name) > -1;
})
setMyMovies(filterA)
}
fetchMyList();
},[account])
const handleNewNotification = ()=>{
dispatch({
type: "error",
message: "pleaser connect your cripto wallet",
title: "not Authenticated",
position: "topL"
})
}
return (
<>
<div className='logo'>
<Logo />
</div>
<div className='connect'>
<Icon fill='#ffffff' svg='bell' size={24}/>
<ConnectButton />
</div>
<div className='topBanner'>
<TabList defaultActiveKey={1} tabStyle="bar">
<Tab tabKey={1} tabName={"Movies"}>
<div className='scene'>
<img src={movies[0].Scene} className="sceneImg"></img>
<img src={movies[0].Logo} className="sceneLogo"></img>
<p className='sceneDesc'>{movies[0].Description}</p>
<div className="playButton">
<Button
type='button'
theme='secundary'
icon='chevronRightX2'
text='play'/>
<Button
type='button'
theme='translucent'
icon='plus'
text='Add to My list'/>
</div>
</div>
<div className='title'>
movies
</div>
<br/>
<div className='thumbs'>
{movies && movies.map(e=>{
return(
<img
className='thumbnail'
src={e.Thumnbnail}
onClick={()=>{setSelectMovie(e);setVisible(true)}}></img>
)
})}
</div>
</Tab>
<Tab tabKey={2} tabName={"series"} isDisabled={true}></Tab>
<Tab tabKey={3} tabName={"MyList"}></Tab>
</TabList>
{selectMovie && (
<div className='modal'>
<Modal
onCloseButtonPressed={()=>setVisible(false)}
isVisible= {visible}
hasFooter = {false}
width = "1000px"
>
<div className='modalContent'>
<img src={selectMovie.Scene} className="modalImg"></img>
<img src={selectMovie.Logo} className="modalLogo"></img>
<div className="modalPlayButton">
{isAuthenticated ? (
<>
<Link to="/player" state={selectMovie.Movie}>
<Button
type='button'
theme='secundary'
icon='chevronRightX2'
text='play'/>
</Link>
<Button
type='button'
theme='translucent'
icon='plus'
text='Add to My list'
onClick={()=>console.log(myMovies)}/>
</>
):(
<>
<Button
type='button'
theme='secundary'
icon='chevronRightX2'
text='play'
onClick={handleNewNotification}/>
<Button
type='button'
theme='translucent'
icon='plus'
text='Add to My list'
onClick={handleNewNotification}/>
</>
)}
</div>
<div className='movieInfo'>
<div className='description'>
<div className='details'>
<span>{selectMovie.Year}</span>
<span>{selectMovie.Duration}</span>
</div>
<span>{selectMovie.Description}</span>
</div>
<div className='detailedInfo'>
Genre:
<span className='deets'>{selectMovie.Genre}</span>
<br/>
Actors:
<span className='deets'>{selectMovie.Actors}</span>
</div>
</div>
</div>
</Modal>
</div>
)}
</div>
</>
)
}
export default Home;
thanksâŚ