transitions working but with timeout which is TO BE FIXED with promisses