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

Use @error rather than @warn #5

Closed
KittyGiraudel opened this issue Jan 27, 2015 · 1 comment
Closed

Use @error rather than @warn #5

KittyGiraudel opened this issue Jan 27, 2015 · 1 comment

Comments

@KittyGiraudel
Copy link
Contributor

Instead of @warning when something goes wrong regarding the Sass logic, I'd advise to throw an error with @error. There is no reason to let the script run when there is an error, so you better throw an actual error.

For instance:

@function ext-get-option($option) {
  @if not map-has-key($ext-opt, $option) {
    @error 'The option `#{$option}` is not defined or part of the options.';
  }

  @return map-get($ext-opt, $option);
}
@jaicab
Copy link
Owner

jaicab commented Jan 27, 2015

Fixed on #8.

@jaicab jaicab closed this as completed Jan 27, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants