Fix bug with newalias function.