connect callback fix