fix(filterAttrs): checks for obj before deleting attribute