- Issue created by @emileg
Our copy paste functionality was broken and looking into it I saw there was a console error regarding not being able to find element on event. Based on this i went and looked into it
Click the scissors icon
try and paste it somewhere else
page just refreshed but content doesnt change
check console see following issue
geysir.js?v=1.x:41 Uncaught TypeError: Cannot read properties of null (reading 'element')
at geysir.js?v=1.x:41:37
at Function.each (jquery.min.js?v=3.7.1:2:3129)
at HTMLAnchorElement.<anonymous> (geysir.js?v=1.x:40:15)
at Function.each (jquery.min.js?v=3.7.1:2:3129)
at ce.fn.init.each (jquery.min.js?v=3.7.1:2:1594)
at HTMLDivElement.<anonymous> (geysir.js?v=1.x:36:23)
at Function.each (jquery.min.js?v=3.7.1:2:3129)
at ce.fn.init.each (jquery.min.js?v=3.7.1:2:1594)
at HTMLLIElement.<anonymous> (geysir.js?v=1.x:31:20)
at HTMLLIElement.dispatch (jquery.min.js?v=3.7.1:2:40035)
wrap this in a if
original code
var element = $(event.element);
if (element.hasClass('geysir-paste')) {
if (href === event.elementSettings.url) {
event.options.url = event.options.url.replace('/' + paragraph_id + '/', '/' + parent_id + '/');
}
}
New code
if (event && event.element) {
var element = $(event.element);
if (element.hasClass('geysir-paste')) {
if (href === event.elementSettings.url) {
event.options.url = event.options.url.replace('/' + paragraph_id + '/', '/' + parent_id + '/');
}
}
}
add this into the existing project and create a new fixed version
/
/
/
Active
2.1
Code