Skip to content
This repository was archived by the owner on May 15, 2023. It is now read-only.

Commit 17f1e69

Browse files
authored
Report a better error message for an empty CompileRequest.Input.path (#56)
1 parent 53cbcdb commit 17f1e69

File tree

3 files changed

+9
-1
lines changed

3 files changed

+9
-1
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
## 1.0.0-beta.13
2+
3+
* Report a better error message for an empty `CompileRequest.Input.path`.
4+
15
## 1.0.0-beta.12
26

37
* Support version 1.0.0-beta.14 of the Sass embedded protocol:

bin/dart_sass_embedded.dart

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,10 @@ void main(List<String> args) {
7575
break;
7676

7777
case InboundMessage_CompileRequest_Input.path:
78+
if (request.path.isEmpty) {
79+
throw mandatoryError("CompileRequest.Input.path");
80+
}
81+
7882
try {
7983
result = sass.compileToResult(request.path,
8084
color: request.alertColor,

pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: sass_embedded
2-
version: 1.0.0-beta.12
2+
version: 1.0.0-beta.13
33
description: An implementation of the Sass embedded protocol using Dart Sass.
44
author: Sass Team
55
homepage: https://github.com/sass/dart-sass-embedded

0 commit comments

Comments
 (0)