Fixed bug with transition callbacks