diff --git a/appnexus/model.py b/appnexus/model.py index 4e0484a..cf79a38 100644 --- a/appnexus/model.py +++ b/appnexus/model.py @@ -74,7 +74,7 @@ def save(self, **kwargs): result = self.create(payload, **kwargs) else: result = self.modify(payload, id=self.id, **kwargs) - return result + return type(self)(result) class Campaign(Model): @@ -86,9 +86,8 @@ def profile(self): class Report(Model): - @classmethod - def download(cls, **kwargs): - return cls.client.get("report-download", **kwargs) + def download(self, **kwargs): + return self.client.get("report-download", id=self.report_id) def create_models(services_list):