pull callback outside