mirror of
https://github.com/mgechev/revive.git
synced 2025-07-01 00:24:54 +02:00
fix: add missing defer when unlocking mutex (#879)
This commit is contained in:
@ -19,7 +19,7 @@ type FunctionLength struct {
|
|||||||
|
|
||||||
func (r *FunctionLength) configure(arguments lint.Arguments) {
|
func (r *FunctionLength) configure(arguments lint.Arguments) {
|
||||||
r.Lock()
|
r.Lock()
|
||||||
r.Unlock()
|
defer r.Unlock()
|
||||||
if !r.configured {
|
if !r.configured {
|
||||||
maxStmt, maxLines := r.parseArguments(arguments)
|
maxStmt, maxLines := r.parseArguments(arguments)
|
||||||
r.maxStmt = int(maxStmt)
|
r.maxStmt = int(maxStmt)
|
||||||
|
Reference in New Issue
Block a user