breidert โ credited cainaru โ .
The only con I can see to the usage of โInstallโ is that, to some end users, that might imply that there must be some โUninstallโ mechanism to recipes (similar to installing/uninstalling an app on your phone or computer).
cainaru โ created an issue.
+ My Ukrainian relatives on my dadโs side are still under threat, the war is not over yet. Letโs not become desensitized please
cainaru โ created an issue.
A while back when testing this, I noticed that other feeds that are using HTTP Basic Auth, but not Oauth, start failing with this patch. I wonder if modifying the submitConfigurationForm
like the following might help (particularly with the failing tests) ?
public function submitConfigurationForm(array &$form, FormStateInterface $form_state, FeedInterface $feed = NULL) {
$feed->setSource($form_state->getValue('source'));
// Only submit these if the feed has the Oauth option present.
if (isset($form_state->getValue('authorization_options')['feed_authorization_setting'])) {
$feed_config = [
'feed_authorization_setting' => $form_state->getValue('authorization_options')['feed_authorization_setting'],
'access_token_url' => $form_state->getValue('authorization_options')['access_token_url'],
'grant_type' => $form_state->getValue('authorization_options')['grant_type'],
'client_id' => $form_state->getValue('authorization_options')['client_id'],
'scope' => $form_state->getValue('authorization_options')['scope'],
'username' => $form_state->getValue('authorization_options')['username'],
];
$client_secret = $form_state->getValue('authorization_options')['client_secret'];
$password = $form_state->getValue('authorization_options')['password'];
// Only save the client secret and/or password if they have been changed.
if (!empty($client_secret)) {
$feed_config['client_secret'] = $client_secret;
}
if (!empty($password)) {
$feed_config['password'] = $password;
}
$feed->setConfigurationFor($this->plugin, $feed_config);
}
}
And perhaps setting the feed_authorization_setting
to FALSE
in defaultFeedConfiguration()
?