Conflicts:
stemmaweb/lib/stemmaweb/Controller/Root.pm
try {
if( $stemmaid eq 'n' ) {
# We are adding a new stemma.
+ $stemmaid = $tradition->stemma_count;
$stemma = $tradition->add_stemma( 'dot' => $dot );
- $stemmaid = $tradition->stemma_count - 1;
+ } elsif( $stemmaid !~ /^\d+$/ ) {
+ return _json_error( $c, 403, "Invalid stemma ID specification $stemmaid" );
} elsif( $stemmaid < $tradition->stemma_count ) {
# We are updating an existing stemma.
$stemma = $tradition->stemma( $stemmaid );