Register ourselves
168454
public function register() {
		if (!$this->is_registered) {
			// Automatically use Sentry if detected
			if ($this->detected_sentry() and Config::$sentry_dsn !== null) {
				$this->add_handler(new Handler\Sentry());
			}

			// If we configured mail, send mail too
			if (Config::$mail_errors_to !== null) {
				$this->add_handler(new Handler\Mail());
			}

			// Always add the application handler
			$this->add_handler(new Handler\Application());

			if (Config::$debug === true) {
				// If we detect Whoops, use that instead of our basic handler
				if ($this->detected_whoops()) {
					$this->add_handler(new Handler\Whoops());
				} else {
					$this->add_handler(new Handler\BasicCLI());
					$this->add_handler(new Handler\Basic());
				}
			} else {
				// If we are not in debug, and we end up as the last handler,
				// send some crude error message to the user's browser.
				$this->add_handler(new Handler\BasicOutput());
			}

			set_error_handler([$this, 'handle_error']);
			set_exception_handler([$this, 'handle_exception']);
			register_shutdown_function([$this, 'handle_shutdown']);

			$this->is_registered = true;
		}
	}
582805
public static function register()
	{
		Container::extensionMethod('addTextOutput', function (Container $_this, $value, $label = NULL) {
			$number = TextOutput::$counter;
			TextOutput::$counter++;
			return $_this["textOutput_" . $number] = new TextOutput($value, $label);
		});
	}
464821
public function register()
    {
        App::bind('WeChatAPI', function()
        {
            return new \FooWeChat\Core\WeChatAPI;
        });

        App::bind('Logie', function()
        {
            return new \FooWeChat\Log\Logie;
        });
    }
975539
public static function register()
	{
		$class = new self();
		Events::addListener(array($class, 'screenLogEventListener'), 'screenLogEvent', EventPriority::NORMAL);
		$bar = Debugger::getBar();
		$bar->addPanel($class);
	}
1200160
private function register() {

		$this->options['labels'] = $this->label;
		if (!isset($this->options['rewrite'])) {
			$this->options['rewrite'] = array('slug' => $this->singular);
		}

		$_self = &$this;

		add_action('init', function () use (&$_self) {
			register_taxonomy($_self->singular, $_self->post_types, $this->options);
		});

	}
621618
public function register()
    {
        $this->registerRevisionRepository();
        $this->registerUserRepository();
        $this->registerGroupRepository();
        $this->registerCredentials();

        $this->registerLoginController();
        $this->registerRegistrationController();
        $this->registerResetController();
        $this->registerActivationController();
    }
981901
public function register()
	{
		$logger = new Writer(
			new Logger($this->app['env']), $this->app['events']
		);

		$this->app->instance('log', $logger);

		// If the setup Closure has been bound in the container, we will resolve it
		// and pass in the logger instance. This allows this to defer all of the
		// logger class setup until the last possible second, improving speed.
		if (isset($this->app['log.setup']))
		{
			call_user_func($this->app['log.setup'], $logger);
		}
	}
459485
def register(username, password):
    
    check_for_cloud_server()
    server = Server(config["cloud_server"]["url"])
    server.create_user(username, password)
1179257
def cli(ctx, overwrite):
    """"""
    credentials_path = os.path.join(os.path.expanduser('~'), '.keep', '.credentials')
    if not os.path.exists(credentials_path):
        click.echo('You are not registered.')
        utils.register()
    else:
        utils.pull(ctx, overwrite)
535129
public static function register() {
		foreach ( [ 'post', 'user' ] as $type ) {
			\register_rest_field(
				'post' === $type ? get_post_types() : $type ,
				self::FIELD_NAME,
				[ 'get_callback' => [ __CLASS__, 'get_' . $type . '_fields' ] ]
			);
		}
	}
440985
public function register()
    {
        $registerConfig = $this->config->getSubConfig(self::REGISTER);
        array_map('register_widget', $registerConfig->getArrayCopy());
    }
659580
def register_app(app):
    "  "

    from .views import users
    app.register_blueprint(users)

    from .oauth import config_oauth
    config_oauth(app)
722152
public function register()
    {
        $this->mergeConfigFrom(__DIR__.'/../config/config.php', 'self-diagnosis');

        $this->app->bind('command.selfdiagnosis', SelfDiagnosisCommand::class);

        $this->commands([
            'command.selfdiagnosis',
        ]);
    }
1208109
def register(self, server_info):
        """"""
        # Path relative to the server directory
        self.path = os.path.relpath(self.filename,
                                    start=server_info['notebook_dir'])

        # Replace backslashes on Windows
        if os.name == 'nt':
            self.path = self.path.replace('\\', '/')

        # Server url to send requests to
        self.server_url = server_info['url']

        # Server token
        self.token = server_info['token']

        url = url_path_join(self.server_url, 'notebooks',
                            url_escape(self.path))

        # Set file url to load this notebook
        self.file_url = self.add_token(url)
983129
function preRegister() {
  _3.default._currencies.forEach(c => {
    _User2.default.underscoreMethod(c.value, 'income', async function (amount, title, type) {
      let user = this;
      let balance = user.get(c.value) + amount || 0;
      if (c.precision !== undefined) {
        balance = _lodash2.default.round(balance, c.precision);
      }
      user.set(c.value, balance);
      let income = new _Income2.default({
        type,
        title,
        amount,
        balance,
        target: 'balance',
        currency: c.value,
        user
      });
      await income.save();
      await user.save();
    });
    if (_User2.default.fields[c.value]) return;
    _User2.default.fields[c.value] = {
      label: c.label,
      type: Number,
      default: 0,
      addonAfter: c.unit
    };
  });
}
35396
def register(self):
        
        if self.register_method == "twine":
            self.register_by_twine()
        if self.register_method == "setup":
            self.register_by_setup()
        if self.register_method == "upload":
            self.upload()
432239
def register(self, provider):
        ''''''
        if isinstance(provider,type):
            provider = provider()
        self[provider.code] = provider