def _import(self, opts):
    if (not opts.filename):
        _exit_if_errors(['--file is needed to import functions'])
    import_functions = _exit_on_file_read_failure(opts.filename)
    import_functions = json.loads(import_functions)
    (_, errors) = self.rest.import_functions(import_functions)
    _exit_if_errors(errors)
    _success('Events imported')
def _import(self, opts):
    if (not opts.filename):
        _exit_if_errors(['--file is needed to import functions'])
    import_functions = _exit_on_file_read_failure(opts.filename)
    import_functions = json.loads(import_functions)
    (_, errors) = self.rest.import_functions(import_functions)
    _exit_if_errors(errors)
    _success('Events imported')