Wrap parseQuery
This commit is contained in:
parent
8e08c1d857
commit
2cf10afb06
2 changed files with 4 additions and 1 deletions
|
@ -1,6 +1,8 @@
|
|||
# 2.0.0-alpha.10
|
||||
* All calls to `Service.parseId` are now affixed with the `<Id>` argument.
|
||||
* Added `uri` getter to `AngelHttp`.
|
||||
* The default for `parseQuery` now wraps query parameters in `new Map<String, dynamic>.from`.
|
||||
This resolves a bug in `package:angel_validate`.
|
||||
|
||||
# 2.0.0-alpha.9
|
||||
* Add `Service.map`.
|
||||
|
|
|
@ -134,7 +134,8 @@ abstract class RequestContext<RawRequest> {
|
|||
/// If [forceParse] is not `true`, then [uri].query will be returned, and no parsing will be performed.
|
||||
Future<Map<String, dynamic>> parseQuery({bool forceParse: false}) {
|
||||
if (_body == null && forceParse != true)
|
||||
return new Future.value(uri.queryParameters);
|
||||
return new Future.value(
|
||||
new Map<String, dynamic>.from(uri.queryParameters));
|
||||
else
|
||||
return parse().then((b) => b.query);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue