fix cursor not found issue