moved the node line height calculation to before the save button is added, which gets rid of the undefined error