Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add server #329

Merged
merged 9 commits into from
Jun 27, 2023
Merged

feat: add server #329

merged 9 commits into from
Jun 27, 2023

Conversation

suzy-g38
Copy link
Collaborator

Related Issue

  • Information about the related issue

Closes: #262

What sort of change have you made:

Added server

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Code style update (formatting, local variables)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update.
  • This change requires a documentation update

How Has This Been Tested?

Checklist

  • My code follows the guidelines of this project.
  • I have performed a self-review of my own code.
  • I have commented on my code, particularly wherever it was hard to understand.
  • I have made corresponding changes to the documentation.
  • My changes generate no new warnings.
  • I have added tests that prove my fix is effective or that my feature works.
  • Any dependent changes have been merged and published in downstream modules.

Code of Conduct

@vercel
Copy link

vercel bot commented Jun 24, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
vibey ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 27, 2023 10:58am

@vercel
Copy link

vercel bot commented Jun 24, 2023

@suzy-g38 is attempting to deploy a commit to the unikonf-vibey Team on Vercel.

A member of the Team first needs to authorize it.

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for creating a pull request for vibey!

We appreciate your contribution and are excited to review your changes. If you have any questions or need additional information, please don't hesitate to let us know. We look forward to working with you to improve vibey. Thanks again for your support!

If you want to keep contributing to open source and want to do it with a supportive and inclusive community, consider joining UniKonf. We help and encourage each other to make regular contributions to open source projects. If you have any questions, do not hesitate to ask. We look forward to having you as part of our community!

Copy link

@github-advanced-security github-advanced-security bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CodeQL found more than 10 potential problems in the proposed changes. Check the Files changed tab for more details.

Copy link
Collaborator

@Deepu178 Deepu178 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@suzy-g38 Please review and fix the security vulnerabilities.

try {
const updatedEvent = await EventModel.findOneAndUpdate(
{ _id: _id },
{ $set: updatedValue },

Check failure

Code scanning / CodeQL

Database query built from user-controlled sources High

This query object depends on a
user-provided value
.

const deleteEvent = async (_id) => {
try {
const event = await EventModel.deleteOne({ _id: _id });

Check failure

Code scanning / CodeQL

Database query built from user-controlled sources High

This query object depends on a
user-provided value
.
try {
const hackathon = await HackathonModel.findOneAndUpdate(
{ _id: _id },
{ $set: updatedValue },

Check failure

Code scanning / CodeQL

Database query built from user-controlled sources High

This query object depends on a
user-provided value
.

const deleteHackathon = async (_id) => {
try {
const hackathon = await HackathonModel.deleteOne({ _id: _id });

Check failure

Code scanning / CodeQL

Database query built from user-controlled sources High

This query object depends on a
user-provided value
.
Comment on lines +41 to +54
userRouter.post('/login', async (req, res) => {
try {
const user = await UserService.loginUser();
if (user === 404) {
res.status(404).json({ message: 'User not found' });
}
if (user === 401) {
res.status(401).json({ message: 'Invalid Credentials' });
}
res.status(200).send({ success: true, user: 'login successful' });
} catch (error) {
res.status(500).json({ success: false, message: 'Internal server error' });
}
});

Check failure

Code scanning / CodeQL

Missing rate limiting High

This route handler performs
authorization
, but is not rate-limited.
try {
const cfps = await CfpModel.findByIdAndUpdate(
_id,
{ $set: updatedValue },

Check failure

Code scanning / CodeQL

Database query built from user-controlled sources High

This query object depends on a
user-provided value
.

const deleteCfp = async (_id) => {
try {
const cfps = await CfpModel.deleteOne({ _id });

Check failure

Code scanning / CodeQL

Database query built from user-controlled sources High

This query object depends on a
user-provided value
.
@Deepu178
Copy link
Collaborator

Thanks @suzy-g38 for making the biggest contribution to the Vibey. You have done a really great job and implemented it perfectly. Let's merge the pr!

@Deepu178 Deepu178 merged commit b37b38d into UniKonf:main Jun 27, 2023
2 of 3 checks passed
@Deepu178 Deepu178 added gssoc23 This label aids in the tracking of issues for octabot used by GSSoC'23 for tracking. level3 Level describing the difficulty nature of the raised issue new feature labels Jun 27, 2023
@suzy-g38
Copy link
Collaborator Author

Thanks @suzy-g38 for making the biggest contribution to the Vibey. You have done a really great job and implemented it perfectly. Let's merge the pr!

Thanks a lot, @Deepu178, I think as a contributor these words mean a lot, and there is no greater satisfaction than this. Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
gssoc23 This label aids in the tracking of issues for octabot used by GSSoC'23 for tracking. level3 Level describing the difficulty nature of the raised issue new feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Shift the backend from Appwrite to Node.js and MongoDB
2 participants