public function rename_on_activation() {
		$plugin_dir = trailingslashit( WP_PLUGIN_DIR );
		$slug       = isset( $_GET['plugin'] ) ? $_GET['plugin'] : false;
		$exploded   = explode( '-', dirname( $slug ) );

		if ( in_array( 'develop', $exploded, true ) ) {
			$options = $this->get_class_vars( 'Base', 'options' );
			update_site_option( 'github_updater', array_merge( $options, [ 'current_branch_github-updater' => 'develop' ] ) );
		}

		if ( $slug && 'github-updater/github-updater.php' !== $slug ) {
			@rename( $plugin_dir . dirname( $slug ), $plugin_dir . 'github-updater' );
		}
	}
public function rename_on_activation() {
		$plugin_dir = trailingslashit( WP_PLUGIN_DIR );
		$slug       = isset( $_GET['plugin'] ) ? $_GET['plugin'] : false;
		$exploded   = explode( '-', dirname( $slug ) );

		if ( in_array( 'develop', $exploded, true ) ) {
			$options = $this->get_class_vars( 'Base', 'options' );
			update_site_option( 'github_updater', array_merge( $options, [ 'current_branch_github-updater' => 'develop' ] ) );
		}

		if ( $slug && 'github-updater/github-updater.php' !== $slug ) {
			@rename( $plugin_dir . dirname( $slug ), $plugin_dir . 'github-updater' );
		}
	}
public function rename_on_activation ( ) { $ plugin_dir = trailingslashit ( WP_PLUGIN_DIR ) ; $ slug = isset ( $ _GET [ 'plugin' ] ) ? $ _GET [ 'plugin' ] : false ; $ exploded = explode ( '-' , dirname ( $ slug ) ) ; if ( in_array ( 'develop' , $ exploded , true ) ) { $ options = $ this -> get_class_vars ( 'Base' , 'options' ) ; update_site_option ( 'github_updater' , array_merge ( $ options , [ 'current_branch_github-updater' => 'develop' ] ) ) ; } if ( $ slug && 'github-updater/github-updater.php' !== $ slug ) { @ rename ( $ plugin_dir . dirname ( $ slug ) , $ plugin_dir . 'github-updater' ) ; } }
Rename on activation.

Correctly renames the slug when GitHub Updater is installed
via FTP or from plugin upload.

Set current branch to `develop` if appropriate.

`rename()` causes activation to fail.

@return void
Rename on activation .