- if ($this->oprofile->subscribe()) {
- SubMirror::saveMirror($this->user, $this->profile);
- } else {
- $this->serverError(_m("Could not subscribe to feed."));
+ $provider = $this->trimmed('provider');
+ switch ($provider) {
+ case 'feed':
+ return $this->trimmed('feedurl');
+ default:
+ // TRANS: Exception thrown when a feed provider could not be recognised.
+ throw new Exception(_m('Internal form error: Unrecognized feed provider.'));