Fixt bug in attsupdate (but not JsHint valid)