Fix prime usage on 1.8.7