From ac9a9962104aa03a52f16e3b00e967e06e0fc318 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Date: Tue, 11 Nov 2014 09:51:55 +0100 Subject: [PATCH] shortcut spell checking if no dictionaries were loaded Change-Id: I2657f34947790eb5ed71f160becbb01399147793 Reviewed-by: Orgad Shaneh <orgads@gmail.com> --- git-hooks/sanitize-commit | 2 ++ 1 file changed, 2 insertions(+) diff --git a/git-hooks/sanitize-commit b/git-hooks/sanitize-commit index 5963e08..64f5172 100755 --- a/git-hooks/sanitize-commit +++ b/git-hooks/sanitize-commit @@ -133,6 +133,8 @@ sub complain_spelling() # Given a line of text, searches for likely spelling errors. sub check_spelling() { + return if (!%MISTAKES_BASE); + my %seen; my (@words) = split(/\b/); foreach my $word (@words) { -- GitLab