added support for removing resources