support old case classes