async restore() {
    logger.debug(
      'Restoring service configuration to its original state in memory',
    )
    this.serverless.service.provider.iam = this.originalIamConfig

    this.serverless.service.getAllFunctions().forEach((functionName) => {
      const functionConfig = this.serverless.service.getFunction(functionName)

      const originalFunctionConfig = this.originalFunctionConfigs[functionName]

      // If the function was not updated, we don't need to restore it
      if (!originalFunctionConfig) {
        return
      }

      const { handler, runtime, environment } = originalFunctionConfig

      functionConfig.handler = handler
      functionConfig.environment = environment
      functionConfig.runtime = this.provider.getRuntime(runtime)
    })
  }
Restores the serverless service configuration to its original state. Specifically:
  1. Resets the IAM configuration.
  2. Resets all function configurations to their original handler, runtime, and environment variables.

@async
@returns {Promise<void>} A promise that resolves once all configurations have been successfully restored.