Fix template last event