solved error caused by passing user variable as reference into the foreach, modification integrated also in user's delete button