Identify submit button in webform
Below codes work for two submit buttons given at webform for identify which button is click.

function modulename_form_submit(&amp;$form, FormStateInterface $form_state) {

  $myurl = FALSE;
  $triggerElement = $form_state-&gt;getTriggeringElement();

  if (isset($triggerElement['#id']) &amp;&amp; $triggerElement['#id'] == 'COMPARE BUTTON ID') {
    $myurl = Url::fromUri('internal:/SETYOURFIRSTACTIONPATH');
  }

  if (isset($triggerElement['#id']) &amp;&amp; $triggerElement['#id'] == 'COMPARE ANOTHER BUTTON ID') {
    $myurl = Url::fromUri('internal:SETYOURSECONDACTIONPATH');
  }

  if ($myurl) {
    $form_state-&gt;setRedirectUrl($myurl);
  }
}