hyper icon indicating copy to clipboard operation
hyper copied to clipboard

Lucee 6 Compat - use of `headers.clone()` throws error

Open jclausen opened this issue 11 months ago • 0 comments

In Lucee 6 the clone method is no longer available on a Struct.

models/HyperRequest.cfc:1286 :

req.setHeaders( variables.headers.clone() );

Throws the following error:

GLOBAL BUNDLE EXCEPTION
-> expression:The function [clone] does not exist in the Struct. Available functions are [append, clear, copy, count, delete, duplicate, each, every, filter, find, findKey, findValue, getMetadata, insert, isEmpty, keyArray, keyExists, keyList, keyTranslate, len, map, numberFormat, reduce, some, sort, toJson, toSorted, update, valueArray].:Only the following functions are available [ append, clear, copy, count, delete, duplicate, each, every, filter, find, findKey, findValue, getMetadata, insert, isEmpty, keyArray, keyExists, keyList, keyTranslate, len, map, numberFormat, reduce, some, sort, toJson, toSorted, update, valueArray ].
-> at /home/runner/work/cbelasticsearch/cbelasticsearch/modules/hyper/models/HyperRequest.cfc:1286 

jclausen avatar Feb 21 '25 18:02 jclausen