Skip to content

Commit

Permalink
pass query & path rightly to server
Browse files Browse the repository at this point in the history
  • Loading branch information
codekeyz committed Feb 4, 2024
1 parent df6f699 commit 07f7925
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions packages/spookie/lib/spookie.dart
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,12 @@ abstract interface class Spookie {
class _$SpookieImpl implements Spookie {
final Uri baseUri;

_$SpookieImpl(this.baseUri) {
_headers.clear();
}
_$SpookieImpl(this.baseUri);

Uri getUri(String path) => baseUri.replace(path: path);
Uri getUri(String p) {
final uri = Uri.parse(p);
return baseUri.replace(path: uri.path, query: uri.query);
}

final Map<String, String> _headers = {};

Expand Down

0 comments on commit 07f7925

Please sign in to comment.