Fixed a bug where attributes could not be cleared