is it necessary to use `apply` here?