Check user permissions before deleting item (fixes gh-14)