minimize call to splice