added the append function