Fixes callback being called to early

Stream was returning before the build was finished.