mybrary's People
Forkers
rogmccoy tiramisuczk eagyekum stefanpgr danggadang srdjanjevtic al-mighty warlinsgit ni-c0de-mus marioleonardo prithvimukesh quietcoder1007 enigman2017 pdji1602003 braimourad prinart pabloarranz kondalavanya67 rakshit6432 kamitom chenshihwei antowrk nikkhil31 amberchunn vjaydeshmukh rkmintx1 leonoronhas andreiandronache98 rivasjon julosmont sushritsaha sydunix afullstackboss heretodesign tingkai911 james15394 mahatorajeev juniorbuking crashdestroyer kamestart acolasso idnk2203 ar606-1 jodyson24 boldmax richardkeep tgmafra indian-techster abdallah-alhajeid mmarin95 jeffreycarey-aon jmckiernan dan-hub-2021 nhanloveyou nico120719 amrit9939 arnzero jeremiahisdev lum1616 faaiz-hadaina babarindeolanrewaju2 krishna4537 alep-hm kamanwu-node hurleywflow bozzlemay linnminhtet23 hcchengithub m-zemmouri aumdavda dflorez0 briansutelus briansu2004 access6080 sylezenwata developer-07 markgordon22 wafa-rtibi ruchitha462 sville anu-aj daredevilstudios clorfts nerdybee akremsalhi benjirez iddam0 iaabdulghani dominodev chuantianlin jemasonmedia enedrehkna dupontdenis helloecho12345 hidding-dev surya-prakash-k nokid7 codehunterdev dev-lester kyzhoemybrary's Issues
I think there is an issue with the renderFormPage function
Hi Kyle!
I think there is an issue with this function
async function renderFormPage(res, book, form, hasError = false) { try { const authors = await Author.find({}) const params = { authors: authors, book: book } if (hasError) { if (form === 'edit') { params.errorMessage = 'Error Updating Book' } else { params.errorMessage = 'Error Creating Book' } } res.render(
books/${form}, params) } catch { res.redirect('/books') } }
On this commit. Here is the repro steps:
1- Start your server (after you have pulled the changes from the commit mentioned above
2- Go to "Add Book" and click it
3- Don't fill in any of the fields and click "Create"
Actual Result:
The browser will keep loading and nothing happens and then the app will crash.
Expected Result:
The app should redirect the user back to the /books/new page and populate all of the fields that were populated at the initial creation of the book. In my case where non of the fields was populated it should bring me back to the /books/new page and all fields should be empty.
Thanks!
Mohammed
req.file is undefined even after uploading the book cover
can't find what's wrong ... req.file is undefined
https://github.com/H-Kanwar/Mybrary/blob/main/routes/books.js
https://github.com/H-Kanwar/Mybrary/tree/main/views/books
How to populate initial files(book cover) from database while editing the book
Author not selected in books edit page
When I tried to edit a book, noted that the author of the book was not selected. I fixed by changing the if(author.id === book.author)
for if(author.id == book.author)
.
Sorry if my english is bad.
TypeError: Cannot read property 'toString' of undefined
C:\Users\ASHU\Desktop\Office node projects\Test\node_modules\dotenv\lib\main.js:41
src.toString().split(NEWLINE).forEach(function (line, idx) {
^
TypeError: Cannot read property 'toString' of undefined
at Object.parse (C:\Users\ASHU\Desktop\Office node projects\Test\node_modules\dotenv\lib\main.js:41:7)
at Object. (C:\Users\ASHU\Desktop\Office node projects\Test\server.js:3:23)
at Module._compile (module.js:653:30)
at Object.Module._extensions..js (module.js:664:10)
at Module.load (module.js:566:32)
at tryModuleLoad (module.js:506:12)
at Function.Module._load (module.js:498:3)
at Function.Module.runMain (module.js:694:10)
at startup (bootstrap_node.js:204:16)
at bootstrap_node.js:625:3
i am facing this error please someone help me i have already replaced the .load() to .parse()
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.