diff options
Diffstat (limited to 'lib/githubexplorer/Schema')
-rw-r--r-- | lib/githubexplorer/Schema/Result/Follow.pm | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/lib/githubexplorer/Schema/Result/Follow.pm b/lib/githubexplorer/Schema/Result/Follow.pm index 735980b..69b9596 100644 --- a/lib/githubexplorer/Schema/Result/Follow.pm +++ b/lib/githubexplorer/Schema/Result/Follow.pm @@ -6,13 +6,12 @@ __PACKAGE__->load_components(qw/Core/); __PACKAGE__->table('follow'); __PACKAGE__->add_columns( - id_follower => { data_type => 'int', }, - id_following => { data_type => 'int' }, + origin => { data_type => 'int', }, + dest => { data_type => 'int' }, ); -__PACKAGE__->set_primary_key(qw/id_follower id_following/); -__PACKAGE__->belongs_to( 'id_follower', - 'githubexplorer::Schema::Result::Profiles' ); -__PACKAGE__->belongs_to( 'id_following', +__PACKAGE__->set_primary_key(qw/origin dest/); +__PACKAGE__->belongs_to( 'origin', 'githubexplorer::Schema::Result::Profiles' ); +__PACKAGE__->belongs_to( 'dest', 'githubexplorer::Schema::Result::Profiles' ); 1; |