Skip to content
This repository has been archived by the owner on Jul 24, 2024. It is now read-only.

Commit

Permalink
Merge pull request #2951 from nschonni/fix--str-slice-can't-start-at-0
Browse files Browse the repository at this point in the history
fix: str-slice can't start at 0
  • Loading branch information
nschonni authored Jul 26, 2019
2 parents 6ea4cb2 + 1c2ae95 commit 2263d9b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/fn_strings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ namespace Sass {
if (end_at > size) { end_at = (double)size; }
if (start_at < 0) {
start_at += size + 1;
if (start_at < 0) start_at = 0;
if (start_at <= 0) start_at = 1;
}
else if (start_at == 0) { ++ start_at; }

Expand Down

0 comments on commit 2263d9b

Please sign in to comment.