[null-safety] fix real type failures in web engine (flutter/engine#20010)

remove extra null checks
This commit is contained in:
Jonah Williams 2020-07-24 12:37:35 -07:00 committed by GitHub
parent a71b077bc9
commit b6aadb0406
2 changed files with 2 additions and 2 deletions

View File

@ -13,7 +13,7 @@ class CkPathMetrics extends IterableBase<ui.PathMetric>
/// The [CkPath.isEmpty] case is special-cased to avoid booting the WASM machinery just to find out there are no contours.
@override
Iterator<ui.PathMetric> get iterator => _path.isEmpty! ? const CkPathMetricIteratorEmpty._() : CkContourMeasureIter(_path, _forceClosed);
Iterator<ui.PathMetric> get iterator => _path.isEmpty ? const CkPathMetricIteratorEmpty._() : CkContourMeasureIter(_path, _forceClosed);
}
class CkContourMeasureIter implements Iterator<ui.PathMetric> {

View File

@ -160,7 +160,7 @@ class Surface {
return _makeSoftwareCanvasSurface(htmlCanvas);
}
return CkSurface(skSurface!, _grContext, glContext);
return CkSurface(skSurface, _grContext, glContext);
}
}