Skip to content

Commit

Permalink
fix maybe and no_init_lists msg
Browse files Browse the repository at this point in the history
  • Loading branch information
bormilan committed Oct 18, 2024
1 parent 6513368 commit f956cf9
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/elvis_style.erl
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
-module(elvis_style).

-feature(maybe_expr, enable).

-export([default/1, function_naming_convention/3, variable_naming_convention/3,
consistent_variable_casing/3, macro_names/3, macro_module_names/3, no_macros/3,
no_specs/3, no_types/3, no_block_expressions/3, operator_spaces/3, no_space/3,
Expand Down Expand Up @@ -33,8 +31,8 @@
no_match_in_condition_config/0, behaviour_spelling_config/0,
param_pattern_matching_config/0, private_data_type_config/0]).

% -define(NO_INIT_LISTS_MSG,
% "Do not use a list as the parameter for the 'init' callback at position ~p.").
-define(NO_INIT_LISTS_MSG,
"Do not use a list as the parameter for the 'init' callback at position ~p.").
-define(INVALID_MACRO_NAME_REGEX_MSG,
"The macro named ~p on line ~p does not respect the format "
"defined by the regular expression '~p'.").
Expand Down Expand Up @@ -1067,7 +1065,7 @@ no_init_lists(Config, Target, RuleConfig) ->
ResultFun =
fun({_, Location, _}) ->
Info = [Location],
Msg = "asd",
Msg = ?NO_INIT_LISTS_MSG,
elvis_result:new(item, Msg, Info, Location)
end,
lists:map(ResultFun, FunListAttributes).
Expand Down

0 comments on commit f956cf9

Please sign in to comment.