PradyumnaKrishna / enigma-protocol

An end to end encrypted messenger using Flask, SocketIO, and Vue.js
https://protocol.onpy.in
MIT License
19 stars 34 forks source link

go-code-modified #102

Closed itsmeabhishek03 closed 4 months ago

itsmeabhishek03 commented 4 months ago

Close #101

I have made some changes in backend go code. These are the changes I made to provide you better reliability and maintainability

1) Returns errors from various functions, allowing the calling code to handle errors and take appropriate action. 2) Uses a function NewConn to open a new connection to the SQLite database and returns both the database connection and an error if any. 3) Uses QueryRow to query the public key. It returns an error if the query fails or if the public key is empty. 4) Returns an error if there's any issue during the user insertion process.

PradyumnaKrishna commented 4 months ago

You might be interested in updating main.go as well because the function return values have been changed.

itsmeabhishek03 commented 4 months ago

@PradyumnaKrishna Ok will look into it but I have doubt will i get any points for this issue just curious to know because codepeak'23 will end on 28th December

PradyumnaKrishna commented 4 months ago

@PradyumnaKrishna Ok will look into it but I have doubt will i get any points for this issue just curious to know because codepeak'23 will end on 28th December

You will get points for the issue raised but not this, it's a minor change. If you get it done I will assign you points for this too.