streamlined some variable assignments