Being not too fluent in Javascript I preferred writing a new function before changing working one :)
They are now unified