LongPress/ShortPress button two functions

Grumpy_Mike:

 if((beginTime >= timeInterval) && (button1State == LOW))

{




Should be


if((millis() >= beginTime + timeInterval) && (button1State == LOW))
  {

I tried this but it did not work, I held the button for over a minute and should have received the response after 20 seconds but I didn't. Not sure what's wrong now. I feel like adding the timeInterval to beginTime will never make millis() greater because beginTime is set to millis().