Skip to content

Commit

Permalink
fix(core): remove useless logger on jsonfilter
Browse files Browse the repository at this point in the history
  • Loading branch information
tchiotludo authored and brian-mulier-p committed Aug 8, 2024
1 parent 8d25894 commit dd45545
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ public List<BinaryOperator> getBinaryOperators() {
return operators;
}

@SuppressWarnings("deprecation")
@Override
public Map<String, Filter> getFilters() {
Map<String, Filter> filters = new HashMap<>();
Expand Down Expand Up @@ -104,6 +105,7 @@ public Map<String, Test> getTests() {
return tests;
}

@SuppressWarnings("deprecation")
@Override
public Map<String, Function> getFunctions() {
Map<String, Function> functions = new HashMap<>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,8 @@
@Slf4j
@Deprecated
public class JsonFilter extends ToJsonFilter {

@Override
public Object apply(Object input, Map<String, Object> args, PebbleTemplate self, EvaluationContext context, int lineNumber) throws PebbleException {
log.warn("The 'json' filter is deprecated, please use 'toJson' instead");

return super.apply(input, args, self, context, lineNumber);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,8 @@
@Slf4j
@Deprecated
public class JsonFunction extends FromJsonFunction {

@Override
public Object execute(Map<String, Object> args, PebbleTemplate self, EvaluationContext context, int lineNumber) {
log.warn("The 'json' function is deprecated, please use 'fromJson' instead");

return super.execute(args, self, context, lineNumber);
}
}

0 comments on commit dd45545

Please sign in to comment.