- my $artist_id;
- if($self->ok($artist))
- {
- $artist_id=$self->add_to_table("artists", $artist);
- $self->add_relation("files_x_artists",
- { "files_id" => $file_id,
- "artists_id" => $artist_id });
- }
-
- if($self->ok($album))
- {
- my $albums_id=$self->add_to_table("albums", $album);
- $self->add_relation("files_x_albums",
- { "files_id" => $file_id,
- "albums_id" => $albums_id});
- if($self->ok($artist))
- {
- $self->add_relation("artists_x_albums",
- { "artists_id" => $artist_id,
- "albums_id" => $albums_id});
- }
- }
-