Alarm off after 2 seconds when distance is less than 10 cm

Hi,
Using an ultrasonic HC-SR04 I want a buzzer to go off for 2 seconds when the distance is less than 10 cm. The buzzer should stop even if the distance stays less than 10 cm. In my code the buzzer is never buzzing. What am I doing wrong?

int trigPin = 13;
int echoPin = 12;
int redLed = 11;
int greenLed = 10;
int buzzer = 9;
long duration;
long distance;
int interval = 2000;
unsigned long lastMillis = 0;
boolean  buzzerState = false;

void setup() {
  Serial.begin (9600);
  pinMode(trigPin, OUTPUT);
  pinMode(echoPin, INPUT);
  pinMode(redLed, OUTPUT);
  pinMode(greenLed, OUTPUT);
  pinMode(buzzer, OUTPUT);
}

void loop() {
  digitalWrite(trigPin, LOW);
  delayMicroseconds(2);
  digitalWrite(trigPin, HIGH);
  delayMicroseconds(10);
  digitalWrite(trigPin, LOW);
  duration = pulseIn(echoPin, HIGH);
  distance = (duration / 2) / 29.1;
  Serial.print(distance);
  Serial.println(" cm");

  if (distance < 10) {

    while ((millis() - lastMillis < interval) && (buzzerState = false)) {
      digitalWrite (buzzer, HIGH);
      digitalWrite(redLed, HIGH);
      digitalWrite(greenLed, LOW);
    }
    digitalWrite(redLed, HIGH);
    digitalWrite(greenLed, LOW);
    digitalWrite(buzzer, LOW);
    buzzerState = true;
  }

  else {
    digitalWrite(redLed, LOW);
    digitalWrite(greenLed, HIGH);
    digitalWrite(buzzer, LOW);

  }
  delay(100);
  lastMillis = millis();
  buzzerState = false;
}

First time round, if it's over 2000ms since reset, and since lastMillis is 0 from its initialisaton, then millis() - lastMillis will already be greater than the interval and the while will not fire.

Should not putting -- lastMillis = millis(); -- just above the while loop fix this?