@@ -3,7 +3,7 @@ package rule
33import (
44 "fmt"
55
6- "github.com/conventionalcommit/commitlint/message "
6+ "github.com/conventionalcommit/commitlint/lint "
77)
88
99// HeadMaxLenRule to validate max length of header
@@ -15,7 +15,7 @@ type HeadMaxLenRule struct {
1515func (r * HeadMaxLenRule ) Name () string { return "header-max-length" }
1616
1717// Validate validates HeadMaxLenRule
18- func (r * HeadMaxLenRule ) Validate (msg * message .Commit ) (string , bool ) {
18+ func (r * HeadMaxLenRule ) Validate (msg * lint .Commit ) (string , bool ) {
1919 return checkMaxLen (r .CheckLen , msg .Header .FullHeader )
2020}
2121
@@ -33,7 +33,7 @@ type BodyMaxLenRule struct {
3333func (r * BodyMaxLenRule ) Name () string { return "body-max-length" }
3434
3535// Validate validates BodyMaxLenRule
36- func (r * BodyMaxLenRule ) Validate (msg * message .Commit ) (string , bool ) {
36+ func (r * BodyMaxLenRule ) Validate (msg * lint .Commit ) (string , bool ) {
3737 return checkMaxLen (r .CheckLen , msg .Body )
3838}
3939
@@ -51,7 +51,7 @@ type FooterMaxLenRule struct {
5151func (r * FooterMaxLenRule ) Name () string { return "footer-max-length" }
5252
5353// Validate validates FooterMaxLenRule
54- func (r * FooterMaxLenRule ) Validate (msg * message .Commit ) (string , bool ) {
54+ func (r * FooterMaxLenRule ) Validate (msg * lint .Commit ) (string , bool ) {
5555 return checkMaxLen (r .CheckLen , msg .Footer .FullFooter )
5656}
5757
@@ -69,7 +69,7 @@ type TypeMaxLenRule struct {
6969func (r * TypeMaxLenRule ) Name () string { return "type-max-length" }
7070
7171// Validate validates TypeMaxLenRule
72- func (r * TypeMaxLenRule ) Validate (msg * message .Commit ) (string , bool ) {
72+ func (r * TypeMaxLenRule ) Validate (msg * lint .Commit ) (string , bool ) {
7373 return checkMaxLen (r .CheckLen , msg .Header .Type )
7474}
7575
@@ -87,7 +87,7 @@ type ScopeMaxLenRule struct {
8787func (r * ScopeMaxLenRule ) Name () string { return "scope-max-length" }
8888
8989// Validate validates ScopeMaxLenRule
90- func (r * ScopeMaxLenRule ) Validate (msg * message .Commit ) (string , bool ) {
90+ func (r * ScopeMaxLenRule ) Validate (msg * lint .Commit ) (string , bool ) {
9191 return checkMaxLen (r .CheckLen , msg .Header .Scope )
9292}
9393
@@ -105,7 +105,7 @@ type DescriptionMaxLenRule struct {
105105func (r * DescriptionMaxLenRule ) Name () string { return "description-max-length" }
106106
107107// Validate validates DescriptionMaxLenRule
108- func (r * DescriptionMaxLenRule ) Validate (msg * message .Commit ) (string , bool ) {
108+ func (r * DescriptionMaxLenRule ) Validate (msg * lint .Commit ) (string , bool ) {
109109 return checkMaxLen (r .CheckLen , msg .Header .Description )
110110}
111111
0 commit comments