Fix - New Language added has no weight
Fix - New Language added has no weight

I'm sorry I didn't take the time to add a test case to underline my fix.

Prior this fix:
But when you added a new record, the new record has no weight set.

The purpose of my fix is to set a weight to a new record.

This case happened when primaryKey field is set but empty.
(cherry picked from commit c13d1ad3b5a9a8f587a219895dc9889f4093844c)

cvo-technologies/croogo,damien-biasotto/croogo,cvo-technologies/croogo,xintesa/croogo,rakeshtembhurne/croogo,Wouter0100/croogo,Wouter0100/croogo,delkyd/croogo,delkyd/croogo,rchavik/croogo,xintesa/croogo,xintesa/croogo,Wouter0100/croogo,cvo-technologies/croogo,rakeshtembhurne/croogo,rchavik/croogo,damien-biasotto/croogo,delkyd/croogo,rakeshtembhurne/croogo