Bug fix nullpointer for PUT without id