diff options
author | Adam Scarr <adam@vektah.net> | 2017-08-10 21:58:14 +1000 |
---|---|---|
committer | Adam Scarr <adam@vektah.net> | 2017-08-10 22:01:06 +1000 |
commit | a0e66b1c46ec57218f8a95a21ace7cbbceb29ec2 (patch) | |
tree | 630056d07ca6b44f7a747b7872ba422c6c301d85 /state.go | |
parent | af542eff9e1e51561a9efa37685ee07b1d01b53e (diff) |
Document cuts
Diffstat (limited to 'state.go')
-rw-r--r-- | state.go | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -92,7 +92,7 @@ func (s *State) Get() string { // Preview of the the next x characters func (s *State) Preview(x int) string { - if s.Pos > len(s.Input) { + if s.Pos >= len(s.Input) { return "" } if len(s.Input)-s.Pos >= x { |