类型错误:/Users/ac/Downloads/BeFound/views/profile.ejs:91

发布于 2025-01-11 06:29:05 字数 1845 浏览 0 评论 0原文

当我单击 Nodejs 应用程序中的页面时出现此错误,我不确定它出了什么问题

TypeError: /Users/ac/Downloads/BeFound/views/profile.ejs:91
    89|                       
    90|                       <div>
 >> 91|                         <%- include('profilePartials/options') %>
    92|                       </div>
    93| 
    94|                      

/Users/ac/Downloads/BeFound/views/profilePartials/options.ejs:5
    3|         <div>
    4|    <div  id="opt-newsfeed">
 >> 5|     <%- include('newsfeed') %> 
    6|    </div>
    7|    <div id="opt-profile">
    8|     <%- include('detailedProfile') %> 

/Users/ac/Downloads/BeFound/views/profilePartials/newsfeed.ejs:268
    266|                                   
    267| 
 >> 268|                                     <img class="commentimg" src="<%= com.createdBy.displayPicture.image %>" alt="altt"
    269|                                     style="border-radius: 50%" />
    270|                                   <% } %>
    271| 

Cannot read properties of undefined (reading 'image')
    at eval ("/Users/ac/Downloads/BeFound/views/profilePartials/newsfeed.ejs":174:55)
    at Proxy.forEach (<anonymous>)
    at eval ("/Users/ac/Downloads/BeFound/views/profilePartials/newsfeed.ejs":141:22)
    at Array.forEach (<anonymous>)
    at eval ("/Users/ac/Downloads/BeFound/views/profilePartials/newsfeed.ejs":15:14)
    at newsfeed 

(/Users/ac/Downloads/BeFound/node_modules/ejs/lib/ejs.js:692:17) 在包括 (/Users/ac/Downloads/BeFound/node_modules/ejs/lib/ejs.js:690:39) 评估时 (“/Users/ac/Downloads/BeFound/views/profilePartials/options.ejs”:12:17) 在选项 (/Users/ac/Downloads/BeFound/node_modules/ejs/lib/ejs.js:692:17) 在包括 (/Users/ac/Downloads/BeFound/node_modules/ejs/lib/ejs.js:690:39)

Got this error when I click on a page in my nodejs app and im not sure what's wrong with it

TypeError: /Users/ac/Downloads/BeFound/views/profile.ejs:91
    89|                       
    90|                       <div>
 >> 91|                         <%- include('profilePartials/options') %>
    92|                       </div>
    93| 
    94|                      

/Users/ac/Downloads/BeFound/views/profilePartials/options.ejs:5
    3|         <div>
    4|    <div  id="opt-newsfeed">
 >> 5|     <%- include('newsfeed') %> 
    6|    </div>
    7|    <div id="opt-profile">
    8|     <%- include('detailedProfile') %> 

/Users/ac/Downloads/BeFound/views/profilePartials/newsfeed.ejs:268
    266|                                   
    267| 
 >> 268|                                     <img class="commentimg" src="<%= com.createdBy.displayPicture.image %>" alt="altt"
    269|                                     style="border-radius: 50%" />
    270|                                   <% } %>
    271| 

Cannot read properties of undefined (reading 'image')
    at eval ("/Users/ac/Downloads/BeFound/views/profilePartials/newsfeed.ejs":174:55)
    at Proxy.forEach (<anonymous>)
    at eval ("/Users/ac/Downloads/BeFound/views/profilePartials/newsfeed.ejs":141:22)
    at Array.forEach (<anonymous>)
    at eval ("/Users/ac/Downloads/BeFound/views/profilePartials/newsfeed.ejs":15:14)
    at newsfeed 

(/Users/ac/Downloads/BeFound/node_modules/ejs/lib/ejs.js:692:17)
at include
(/Users/ac/Downloads/BeFound/node_modules/ejs/lib/ejs.js:690:39)
at eval
("/Users/ac/Downloads/BeFound/views/profilePartials/options.ejs":12:17)
at options
(/Users/ac/Downloads/BeFound/node_modules/ejs/lib/ejs.js:692:17)
at include
(/Users/ac/Downloads/BeFound/node_modules/ejs/lib/ejs.js:690:39)

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文