fixed error message alignment and membership index