getSnapshot method Null safety

Future<HeapSnapshotGraph> getSnapshot()

Implementation

Future<vm.HeapSnapshotGraph> getSnapshot() async {
  vm.VmService virtualMachine = await getVMService();
  vm.Isolate isolate = await getIsolate();
  return vm.HeapSnapshotGraph.getSnapshot(virtualMachine, isolate);
}