def is_valid_command(command)
      valid_commands = ["open", "close", "rsp", "syslog"]
      if !valid_commands.include?(command)
        @logger.error 'Invalid RELP command'
        raise Relp::InvalidCommand.new('Invalid command')
      end
    end
def is_valid_command(command)
      valid_commands = ["open", "close", "rsp", "syslog"]
      if !valid_commands.include?(command)
        @logger.error 'Invalid RELP command'
        raise Relp::InvalidCommand.new('Invalid command')
      end
    end
def is_valid_command ( command ) valid_commands = [ "open" , "close" , "rsp" , "syslog" ] if ! valid_commands . include? ( command ) @logger . error 'Invalid RELP command' raise Relp :: InvalidCommand . new ( 'Invalid command' ) end end
Check if command is one of valid commands if not raise exception
Check if command is one of valid commands if not raise exception