Commit 6c64233f authored by Felip Manyer i Ballester's avatar Felip Manyer i Ballester
Browse files

Issue #3282696: Port of l10n_community: translation form (submit)

parent a93acb12
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -885,7 +885,7 @@ class TranslateForm extends FormBase implements TrustedCallbackInterface {
        if (isset($options['value']) && is_array($options['value'])) {
          foreach ($options['value'] as $key => $value) {
            $all_values++;
            if ($value === t('<New translation>')) {
            if ($value === (string) t('<New translation>')) {
              $options['value'] = '';
              $empty_values++;
            }
+3 −0
Original line number Diff line number Diff line
@@ -391,6 +391,9 @@ class L10nPo {
   * @param bool $force
   *   Force replacing a suggestion if it already exists.
   *
   * @return int
   *   Translation ID.
   *
   * @throws \Exception
   */
  public static function addSuggestion(int $sid, string $translation, string $langcode, int $uid_attribution, int $uid_user, string $medium, bool $force = FALSE) {