GM-6681: FIxing enum cast