# frozen_string_literal: true
module VagrantBindfs
  module Vagrant
    module Capabilities
      module Linux
        module SystemChecks
          class << self
            def bindfs_exists_user(machine, user)
              (
                user.nil? || \
                machine.communicate.test("getent passwd #{user.to_s.shellescape}")
              )
            end

            def bindfs_exists_group(machine, group)
              (
                group.nil? || \
                machine.communicate.test("getent group #{group.to_s.shellescape}")
              )
            end
          end
        end
      end
    end
  end
end

# frozen_string_literal: true
module VagrantBindfs
  module Vagrant
    module Capabilities
      module Linux
        module SystemChecks
          class << self
            def bindfs_exists_user(machine, user)
              (
                user.nil? || \
                machine.communicate.test("getent passwd #{user.shellescape}")
              )
            end

            def bindfs_exists_group(machine, group)
              (
                group.nil? || \
                machine.communicate.test("getent group #{group.shellescape}")
              )
            end
          end
        end
      end
    end
  end
end

Revert "Fix when input is a symbol"
Revert "Fix when input is a symbol"

This reverts commit 56ec5e0f0b080a3d1d08fdc51b5a3ddb540fa086.
