small bug fix with assignment