public function handleStrategy($funcName, $data, $form, $request) {
		if(func_num_args() < 4) {
			throw new LogicException('Must be called with a strategy handler');
		}
		// Trim handleStrategy from the function name:
		$strategy = substr($funcName, strlen('handleStrategy')) . 'Strategy';

		// Check the strategy is good
		if(!class_exists($strategy) || $strategy instanceof OpauthStrategy) {
			throw new InvalidArgumentException('Opauth strategy ' . $strategy . ' was not found or is not a valid strategy');
		}

		return $this->controller->redirect(
			Controller::join_links(
				OpauthController::get_path(),
				OpauthAuthenticator::get_strategy_segment($strategy)
			)
		);
	}
public function handleStrategy($funcName, $data, $form, $request) {
		if(func_num_args() < 4) {
			throw new LogicException('Must be called with a strategy handler');
		}
		// Trim handleStrategy from the function name:
		$strategy = substr($funcName, strlen('handleStrategy')) . 'Strategy';

		// Check the strategy is good
		if(!class_exists($strategy) || $strategy instanceof OpauthStrategy) {
			throw new InvalidArgumentException('Opauth strategy ' . $strategy . ' was not found or is not a valid strategy');
		}

		return $this->controller->redirect(
			Controller::join_links(
				OpauthController::get_path(),
				OpauthAuthenticator::get_strategy_segment($strategy)
			)
		);
	}
public function handleStrategy ( $ funcName , $ data , $ form , $ request ) { if ( func_num_args ( ) < 4 ) { throw new LogicException ( 'Must be called with a strategy handler' ) ; } // Trim handleStrategy from the function name: $ strategy = substr ( $ funcName , strlen ( 'handleStrategy' ) ) . 'Strategy' ; // Check the strategy is good if ( ! class_exists ( $ strategy ) || $ strategy instanceof OpauthStrategy ) { throw new InvalidArgumentException ( 'Opauth strategy ' . $ strategy . ' was not found or is not a valid strategy' ) ; } return $ this -> controller -> redirect ( Controller :: join_links ( OpauthController :: get_path ( ) , OpauthAuthenticator :: get_strategy_segment ( $ strategy ) ) ) ; }
Global endpoint for handleStrategy - all strategy actions point here.
@throws LogicException This should not be directly called.
@throws InvalidArgumentException The strategy must be valid and existent
@param string $funcName The bound function name from addWrapperMethod
@param array $data Standard data param as part of form submission
@param OpauthLoginForm $form
@param SS_HTTPRequest $request
@return ViewableData
Global endpoint for handleStrategy - all strategy actions point here .