fixed problem with insert callback