heroku/heroku.py — pull request #6 by ojii (2012-04-11 13:59:14+00:00)
Title: Allow adding domains to an app that does not have domains yet.

Currently, trying to ``cloud.apps[0].domains.add('mydomain.com')`` does not work if ``cloud.apps[0]`` does not have domains yet, as in this case the ``app`` keyword to ``heroku.api.HerokuCore._get_resources`` from ``heroku.models.App.domains`` is lost. This patch stores the keyword arguments passed to ``_get_resources`` on the ``KeyedListResource`` and uses it in its ``add`` method.