solve a paining problem & some `smartparens' changes