Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cast value correctly in putIfAbsentAsync #1404

Merged
merged 3 commits into from Jul 19, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
@@ -1,3 +1,7 @@
## 1.35.3

* No user-facing changes.

## 1.35.2

* **Potentially breaking bug fix**: Properly throw an error for Unicode ranges
Expand Down
2 changes: 1 addition & 1 deletion lib/src/utils.dart
Expand Up @@ -369,7 +369,7 @@ Future<Iterable<F>> mapAsync<E, F>(
/// same key.
Future<V> putIfAbsentAsync<K, V>(
Map<K, V> map, K key, Future<V> ifAbsent()) async {
if (map.containsKey(key)) return map[key]!;
if (map.containsKey(key)) return map[key] as V;
var value = await ifAbsent();
map[key] = value;
return value;
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
@@ -1,5 +1,5 @@
name: sass
version: 1.35.2
version: 1.35.3-dev
description: A Sass implementation in Dart.
author: Sass Team
homepage: https://github.com/sass/dart-sass
Expand Down