Fix extra bracket, add extra function