Reputation: 60
I can't seem to find what to use instead of this, but here's what I had before:
using ServiceStack.Common.Utils;
...
public Profile Put(ProfileUpdate req) {
var cred = this.GetCredential();
this.AskUser();
var data = Db.GetById<Profile>(cred.UserId);
ReflectionUtils.PopulateObject<Profile, ProfileUpdatable>(data, req);
Now I can't find where Utils or ReflectionUtils or PopulateObject has gone in version 4.0.20
Upvotes: 0
Views: 101
Reputation: 21521
Those functions have been replaced with these auto mapping functions, documented here.
So you would use:
var data = Db.GetById<Profile>(cred.UserId);
data.PopulateWith(req);
Upvotes: 2