Skip to content

Commit 5d4950d

Browse files
authored
Fix bug with null values in configuration (#1305)
Fixes #1281.
1 parent be2d3e8 commit 5d4950d

File tree

4 files changed

+8
-4
lines changed

4 files changed

+8
-4
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
## 1.32.13
22

3+
* **Potentially breaking bug fix:** Null values in `@use` and `@forward`
4+
configurations no longer override the `!default` variable, matching the
5+
behavior of the equivalent code using `@import`.
6+
37
* Use the proper parameter names in error messages about `string.slice`
48

59
## 1.32.12

lib/src/visitor/async_evaluate.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1918,7 +1918,7 @@ class _EvaluateVisitor
19181918
if (node.isGuarded) {
19191919
if (node.namespace == null && _environment.atRoot) {
19201920
var override = _configuration.remove(node.name);
1921-
if (override != null) {
1921+
if (override != null && override.value != sassNull) {
19221922
_addExceptionSpan(node, () {
19231923
_environment.setVariable(
19241924
node.name, override.value, override.assignmentNode,

lib/src/visitor/evaluate.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
// DO NOT EDIT. This file was generated from async_evaluate.dart.
66
// See tool/grind/synchronize.dart for details.
77
//
8-
// Checksum: acaafcfe17e8cb582fb01ea8b95afaf871af4eed
8+
// Checksum: 648f9a2041613a8f11c46986b4b4d4ccbaa0c489
99
//
1010
// ignore_for_file: unused_import
1111

@@ -1910,7 +1910,7 @@ class _EvaluateVisitor
19101910
if (node.isGuarded) {
19111911
if (node.namespace == null && _environment.atRoot) {
19121912
var override = _configuration.remove(node.name);
1913-
if (override != null) {
1913+
if (override != null && override.value != sassNull) {
19141914
_addExceptionSpan(node, () {
19151915
_environment.setVariable(
19161916
node.name, override.value, override.assignmentNode,

pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: sass
2-
version: 1.32.13-dev
2+
version: 1.32.13
33
description: A Sass implementation in Dart.
44
author: Sass Team
55
homepage: https://github.com/sass/dart-sass

0 commit comments

Comments
 (0)