Skip to content

Replace deprecated method $mathtool.toNumber with $numbertool.toNumber in Content Report Table Macro #175

@petrenkonikita112263

Description

@petrenkonikita112263

After triggering Content Report Table Macro according to example in documentation page {{content-report-table labels="macro"/}} you'll see a warning informative message in XWiki console

2023-10-30 13:54:57,193 [qtp532854629-651 - http://localhost/xwiki/bin/view/Sandbox/Test%20Pro%20Macros/?xpage=get&outputTitle=true&language=en&timestamp=1698666896729] WARN  o.a.v.introspection            - Deprecated usage of method [org.apache.velocity.tools.generic.MathTool.toNumber] in xwiki:Sandbox.Test Pro Macros.WebHome@37,43

This method $mathtool.toNumber is only present on one macro AFAIS.

#set($discard = $query.setLimit($mathtool.toNumber($maxResults)).addFilter('currentlanguage'))

Might be good to replace it with $numbertool.toNumber even though this type of message can be disabled on XWiki instance.

Metadata

Metadata

Assignees

Type

No type

Projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions