If the preceding incident happened on Saturday evening and Judas betrayed Jesus on Wednesday, Mary's act of extravagance did not lead Judas to betray Jesus immediately. The Gospel writers did not explain Judas' reasons for betraying Jesus explicitly. It was evidently Judas' initiative in offering to betray Jesus that led the Sanhedrin to move up their timetable for Jesus' execution. If Judas handed Jesus over to them, they could avoid the hostility of the crowds (cf. v. 2; Luke 22:6).
Even though Mary's act of devotion is the high point of this section, providing an excellent example for disciple readers, the dark undercurrent of betrayal is its dominant feature. The religious leaders, Judas, and even the disciples manifested opposition to glorifying Jesus. This attitude was a source of suffering for the Servant.