From 6b7db32933a97b95ec11ed50af5427d55700fe0f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20F=C3=B6hring?= Date: Mon, 10 Jun 2019 08:10:39 +0200 Subject: [PATCH] Fix #660 --- lib/credo/check/consistency/space_around_operators.ex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/credo/check/consistency/space_around_operators.ex b/lib/credo/check/consistency/space_around_operators.ex index 5cb573ed5..d54fcf254 100644 --- a/lib/credo/check/consistency/space_around_operators.ex +++ b/lib/credo/check/consistency/space_around_operators.ex @@ -136,7 +136,7 @@ defmodule Credo.Check.Consistency.SpaceAroundOperators do defp number_in_fun?(line, column) do line |> String.slice(0..(column - 2)) - |> String.match?(~r/[\.\&][a-z0-9_]+$/) + |> String.match?(~r/[\.\&][a-z0-9_]+[\!\?]?$/) end # TODO: this implementation is a bit naive. improve it.