Fix default params in js function for buttons