You did great job Thanks a lot bro. U made go so simple
@zohaibmomin17312 жыл бұрын
why was there no log message Listening at port ..... How will you know server is started
@mohammadminhaziftekhar40742 жыл бұрын
Connection was forcibly closed by a peer. - this error occurs 😥😥
@ochiojie2 жыл бұрын
I faced the same thing brother, I closed everything and tried it all again and it worked
@blackattitude53736 ай бұрын
please help me,idk how to import packages in different programs like,from models program we have to import thw whole model package into controller's program,and the controller package we have to import it in routers program and lastly routers we have to import in main.go
@shahanahmedkhan61015 ай бұрын
I used docker container for mongodb, If you configure p10k on your terminal then you'll have intellisense while writing commands on cli
@andreaseneres95814 ай бұрын
Hi, I have multiple collections like (attendance, employees, departments), it it good practice to connect to these in the init func like this? because my helpers are in another file and when I access the mongo.client variable there its returning nil // DepartmentCol = client.Database(db).Collection("Departments") // AttendanceCol = client.Database(db).Collection("Attendance") or what could be a workaround here? thank you very much
@ukwuteyinoreneojo4159 Жыл бұрын
Once i great a folder in my golang project folder it can not access the gorilla mux
@EmeraldLS2 жыл бұрын
I'm getting an error which says invalid user info
@aumradia539710 ай бұрын
while entering password in the connectionstring remove "" and then try to build.
@abhaysingh.632 Жыл бұрын
I tried and created a simple program to handle .env.json files which sets the environment variables when LoadEnv() is called! (as an Ex-*a*aScript dev it has became essential for me) (it does not works as intended because somehow controllers init() function runs before main.go's init() function) I think this is due to how packages are imported. So a simple solution for this is what I've done is create a new empty file which in returns sends a function of "API is Live" and has a init() function in it which loads before all the files I've imported hence problem solved!!!
@rakeshkumarnahak5320 Жыл бұрын
Ohh ki video ta wa mastre! (Comment in odia)
@kartikrajput2131 Жыл бұрын
has anyone solved the same _id problem?
@codingchannel62632 ай бұрын
Header is set incorrectly, it should be this -----> w.Header().Set("Content-Type", "application/json") w.Header().Set("Allow-Control-Allow-Methods", "POST")
@nayyershahzad80512 жыл бұрын
Excellent
@codingchannel62632 ай бұрын
"Allow-Control-Allow-Methods" ----> It should be -----> "Access-Control-Allow-Methods"