Added more error info
Don't fail when target is not an object
Handle when target wants a JsonValue
Cleaned up code