1 # This module is part of debbugs, and is released
2 # under the terms of the GPL version 2, or any later version. See the
3 # file README and COPYING for more information.
4 # Copyright 2017 by Don Armstrong <don@donarmstrong.com>.
6 package Debbugs::DB::ResultSet::Suite;
10 Debbugs::DB::ResultSet::Suite - Suite table actions
25 use base 'DBIx::Class::ResultSet';
28 my ($self,$suite) = @_;
30 if (ref($suite) eq 'HASH') {
33 $suite = $suite->id();
37 if ($suite !~ /^\d+$/) {
38 $suite = $self->result_source->schema->
40 search_rs({codename => $suite},
41 {result_class => 'DBIx::Class::ResultClass::HashRefInflator',
44 $suite = $suite->{id};