timbunce / WebAPI-DBIC

A composable RESTful JSON API to DBIx::Class schemas using roles and Web::Machine. PLEASE NOTE This module is no longer under active development. If you're interested in helping to develop or maintain it please fork it.
26 stars 10 forks source link

Refactor opportunity (requires DBIC 0.082801+) #8

Open ribasushi opened 9 years ago

ribasushi commented 9 years ago

Hi Tim!

As you said yourself in comments - the codebase contains a hack: https://github.com/timbunce/WebAPI-DBIC/blob/master/lib/WebAPI/DBIC/Resource/Role/Relationship.pm#L69-L115

You should be able to delete your code and use this instead: https://github.com/dbsrgits/dbix-class/blob/current/for_cpan_index/lib/DBIx/Class/ResultSource.pm#L1832-L1853. It will be available on CPAN next week it looks like: http://lists.scsys.co.uk/pipermail/dbix-class/2014-September/011773.html

Cheers ;)

timbunce commented 9 years ago

Now we're requiring a recent DBIC version, any chance you could work on a pull request for this?