Fixed error with callback