Fixed bug where deleting a device doesn't work if device ID contains URL encoded characters.