Art. 461. Where the court has stopped the enforcement of the decision or has declared the election result invalid, the mayor whose term of credentials has expired, provided the said mayor was not registered as a candidate, and in the rest of the cases, the acting mayor shall continue to execute the functions thereof until the newly elected mayor takes the oath of office.