Fixed to js... Deletion now works