Remove/hide Vertical tabs on node edit forms

Node edit forms are not the nicest thing you have seen and new layouts in Drupal 8 that basically copies wordpress style forms are much better. Sometimes you will have clients that can't stand this vertical tabs and would rather not have them at all and probably they will never use them anyway. So best thing to do is to remove them for them. Just add this to your module, which will hide them for them and for user 1 you will still see them.

function custom_form_node_form_alter(&$form, &$form_state) {
global $user;

if ($user->uid != 1){
    foreach ($form as $key => $value) {
      if (is_array($form[$key]) && isset($form[$key]['#group'])) {