I'm trying to make a ternary operator in scala but actually it seems that the `'?'` character cannot be resolved

here is the completed method

```
object Credit {
  def getMaximumWeek(orderId: Int, locale: String): Int = {
    val orderCompletedHistoryCount = Order.getOrderCompletedHistoryCount(orderId, locale);
   orderCompletedHistoryCount == 0 ? 0: Order.getMaximumAllowedWeeks(orderId, locale)
  }
}

```

referenced to this [link](https://alvinalexander.com/scala/scala-ternary-operator-syntax)
,**I'm getting an error connot resolve symbol '?'** even both method are returning integers