The call to dynamic_sidebar() is in the opening if statement: <?php if ( ! dynamic_sidebar( 'sidebar-1' ) ) : ?>
The logic is, if dynamic_sidebar() outputs something, it returns true, causing the contents of the if not to be executed. If it doesn’t display anything (ie. no widgets) then it returns false, and as such, the contents of the if are displayed.