Don't pass "null" to debugPrint. (#11265)

debugDumpLayerTree in particular was passing null in profile mode since debugLayer isn't available in profile mode.
This commit is contained in:
Ian Hickson
2017-07-19 12:57:13 -07:00
committed by GitHub
parent 1744e8e0aa
commit 77b0c1dab0

View File

@@ -309,12 +309,12 @@ abstract class RendererBinding extends BindingBase with SchedulerBinding, Servic
/// Prints a textual representation of the entire render tree.
void debugDumpRenderTree() {
debugPrint(RendererBinding.instance?.renderView?.toStringDeep());
debugPrint(RendererBinding.instance?.renderView?.toStringDeep() ?? 'Render tree unavailable.');
}
/// Prints a textual representation of the entire layer tree.
void debugDumpLayerTree() {
debugPrint(RendererBinding.instance?.renderView?.debugLayer?.toStringDeep());
debugPrint(RendererBinding.instance?.renderView?.debugLayer?.toStringDeep() ?? 'Layer tree unavailable.');
}
/// Prints a textual representation of the entire semantics tree.