104104 description:
105105 - If V(true), the payload matches Rocket.Chat prior to 7.4.0 format. This format has been used by the module since its
106106 inception, but is no longer supported by Rocket.Chat 7.4.0.
107- - The default value of the option is going to change to V(false) eventually .
107+ - The default value of the option, V(true), is B(deprecated) since community.general 11.2.0 and will change to V(false) in community.general 13.0.0 .
108108 - This parameter is going to be removed in a future release when Rocket.Chat 7.4.0 becomes the minimum supported version.
109109 type: bool
110- default: true
111110 version_added: 10.5.0
112111"""
113112
@@ -230,7 +229,7 @@ def main():
230229 validate_certs = dict (default = True , type = 'bool' ),
231230 color = dict (type = 'str' , default = 'normal' , choices = ['normal' , 'good' , 'warning' , 'danger' ]),
232231 attachments = dict (type = 'list' , elements = 'dict' ),
233- is_pre740 = dict (default = True , type = 'bool' )
232+ is_pre740 = dict (type = 'bool' )
234233 )
235234 )
236235
@@ -247,6 +246,15 @@ def main():
247246 attachments = module .params ['attachments' ]
248247 is_pre740 = module .params ['is_pre740' ]
249248
249+ if is_pre740 is None :
250+ module .deprecate (
251+ "The default value 'true' for 'is_pre740' is deprecated and will change to 'false' in community.general 13.0.0."
252+ " You can explicitly set 'is_pre740' in your task to avoid this deprecation warning" ,
253+ version = "13.0.0" ,
254+ collection_name = "community.general" ,
255+ )
256+ is_pre740 = True
257+
250258 payload = build_payload_for_rocketchat (module , text , channel , username , icon_url , icon_emoji , link_names , color , attachments , is_pre740 )
251259 do_notify_rocketchat (module , domain , token , protocol , payload )
252260
0 commit comments