Handle multiple calls of a redefined function