DamyanBG / real-estate-nodejs-be

Real Estate back end rest api application
6 stars 11 forks source link

Adding verifyToken & verifyRole to land #156

Closed AyoubTahir closed 1 year ago

AyoubTahir commented 1 year ago

I have implemented two middlewares (verifyToken and verifyRole).

verifyToken middleware: Ensures that only authenticated users can perform CRUD operations on the land.

verifyRole middleware+ updates to the logic of the landService file: Only the admin and owner can delete, and update. Both the admin and seller can create land.

AyoubTahir commented 1 year ago

I will work on the test next