fuel/orm — pull request #273 by philipptempel (2013-06-20 14:19:33+00:00)
Title: Bug in \Orm\Model_Nestedset::save() when using primary-key different to 'id'

Found this by accident, when starting to use ORM's Nestedset model. Method ```save()``` would throw an exception if the model's primary-key isn't set to 'id' but something else (like 'node_id', or whatever).

This commit fixes this bug by chaning ```\DB::select('id')``` to ```\DB::select($pk)``` where ```$pk = reset(static::$_primary_key)```

Signed-off-by: Philipp Tempel