NicolasSiver / nodebb-plugin-ns-awards

A system for rewarding forum users. The plugin allows admin to define set of awards that could be granted to users for special accomplishments.
https://community.nodebb.org/topic/4397/nodebb-plugin-ns-awards-ns-awards-give-medals
MIT License
31 stars 24 forks source link

Error on creating a new award #58

Open ShlomiPorush opened 2 years ago

ShlomiPorush commented 2 years ago

Error did occur: {"errno":-2,"code":"ENOENT","syscall":"copyfile","path":"/run/nodebb/node_modules/nodebb-plugin-ns-awards/public/uploads/award-dcc3c7ac-1659-42d0-a988-9ab0cab7db46.jpg","dest":"/app/code/public/uploads/awards/award-dcc3c7ac-1659-42d0-a988-9ab0cab7db46.jpg"}

image

NicolasSiver commented 2 years ago

Check your NodeBB installation. For some reason, the Plugin can not write the newly uploaded reward. You should check the user behind your NodeBB and if they can write files here:

Frozen-byte commented 1 year ago

got the same issue when I use the plugin on localhost on Linux.

Server answers:

{
    "errno": -2,
    "code": "ENOENT",
    "syscall": "copyfile",
    "path": "/home/frozen_byte/Projects/nodebb-plugin-ns-awards/public/uploads/award-2611e152-4610-4c52-b7ad-53ac5b3e3bb2.png",
    "dest": "/home/frozen_byte/Projects/NodeBB/public/uploads/awards/award-2611e152-4610-4c52-b7ad-53ac5b3e3bb2.png"
}

So I checked and the "awards" folder was missing, created it manually and it worked.

Anyway the missing folder should create automatically IMHO