Remove redundant property from ExampleResults

master 1.1.0
Oystein Kristoffer Tveit 2020-06-30 12:51:45 +02:00
parent 5ae14e60b7
commit 1317402894
3 changed files with 4 additions and 7 deletions

View File

@ -2,6 +2,7 @@
- Export object interfaces for both libraries
- Add documentation for object interfaces
- Remove accidental redundant property "phrase" from ExampleResults
## 1.0.2

View File

@ -120,7 +120,6 @@ ExampleResults parseExamplePageData(String pageHtml, String phrase) {
query: phrase,
found: results.isNotEmpty,
results: results ?? [],
uri: uriForExampleSearch(phrase),
phrase: phrase,
uri: uriForExampleSearch(phrase)
);
}

View File

@ -154,18 +154,15 @@ class ExampleResults {
String uri;
/// The examples that were found, if any.
List<ExampleResultData> results;
String phrase;
ExampleResults({this.query, this.found, this.results, this.uri, this.phrase});
ExampleResults({this.query, this.found, this.results, this.uri});
Map<String, dynamic> toJson() {
return {
'query': query,
'found': found,
'results': results,
'uri': uri,
'phrase': phrase
'uri': uri
};
}
}