From what hell dart appending me bracket on this serve as?

I’ve a protracted String – []( which I wish to convert to Map<String, double> in beneath serve as:

import ‘dart:math’;
import ‘dart:convert’;

Long run<Map<String, String>> converString() async {

String geom = ”
String cuttedString = geom.substring(20, geom.duration – 2);
String house =’ ‘;

String finalString = house+cuttedString;
Record<String> splitList = finalString.break up(‘,’);

ultimate Map<String, String> values = {};
for (var part in splitList) {
Record<String> longLangList = part.break up(‘ ‘);

String longString = longLangList[1];
String lingString = longLangList[2];

double lengthy = double.parse(longString);
double ling = double.parse(lingString);

ultimate Map<String, double> values = {‘lengthy’: lengthy, ‘ling’:ling };


go back values;

But if serve as succeed in final thing in loop, it in some way append to it “)”, and double.parse() crasing app. When I am printing cuttedString it appears high quality, with out bracket. What the hell?

View Reddit by way of Particular_Hunt9442View Supply

You may also like...

WP2Social Auto Publish Powered By :