adjust for Scala: old class handling