summaryrefslogtreecommitdiffstats
path: root/languages
diff options
context:
space:
mode:
authorMurilo Ijanc <[email protected]>2026-07-27 20:52:15 -0300
committerMurilo Ijanc <[email protected]>2026-07-27 20:52:15 -0300
commit511a0ab33b5b12a4cd8a1d4dca6c5dce50cdb6c1 (patch)
tree462412b439743c2d04f1acf24f6557251d3a8265 /languages
parent535dbda6b48171f8115b455e54790de94d97d42a (diff)
downloadwoocommerce-511a0ab33b5b12a4cd8a1d4dca6c5dce50cdb6c1.tar.gz
Name the municipality behind a CEP that does not existHEADv0.2.0main
A CEP that fails at the checkout is almost never a random number. It is a shopper who knows perfectly well which town they live in and got a digit wrong, most often by reaching for the -000 that 957 municipalities never received. The API now names the municipality such a number would have belonged to, in the body of its own 404, so the message can say "that would be in Areal/RJ, which has CEPs from 25845-001 to 25849-899" instead of leaving the shopper at a dead end with nothing to act on. It stays an error. Nothing from it is written into a checkout field, on either checkout and in either lookup mode: a CEP that does not exist has no address, and filling one in from the municipality behind it means a parcel delivered to the wrong town and a chargeback behind that. The one module that reads the 404 body hands its callers a finished sentence and never the data itself, so there is no shape in which it could leak into a field later. The two CEPs quoted are the lowest and the highest that really exist there, never a list and never a suggestion, because the range is sparse enough that a number out of the middle of it would most likely not exist either. The widget correctly throws its 404 away without reading it, so the body is fetched once more, on the miss path only and once per CEP. In proxy mode PHP passes the municipality through with the 404 and caches it with the miss, which is what keeps the two modes indistinguishable from the browser. Anything missing or misshapen falls back to the message the plugin has always shown.
Diffstat (limited to 'languages')
-rw-r--r--languages/cepis-woocommerce-pt_BR.mobin4292 -> 4693 bytes
-rw-r--r--languages/cepis-woocommerce-pt_BR.po12
2 files changed, 11 insertions, 1 deletions
diff --git a/languages/cepis-woocommerce-pt_BR.mo b/languages/cepis-woocommerce-pt_BR.mo
index 961e3e8..78ac83d 100644
--- a/languages/cepis-woocommerce-pt_BR.mo
+++ b/languages/cepis-woocommerce-pt_BR.mo
Binary files differ
diff --git a/languages/cepis-woocommerce-pt_BR.po b/languages/cepis-woocommerce-pt_BR.po
index 1169624..1547469 100644
--- a/languages/cepis-woocommerce-pt_BR.po
+++ b/languages/cepis-woocommerce-pt_BR.po
@@ -1,6 +1,6 @@
msgid ""
msgstr ""
-"Project-Id-Version: CEP Autofill for WooCommerce 0.1.0\n"
+"Project-Id-Version: CEP Autofill for WooCommerce 0.2.0\n"
"Report-Msgid-Bugs-To: https://cep.is\n"
"PO-Revision-Date: 2026-07-26 00:00+0000\n"
"Last-Translator: Murilo Ijanc <[email protected]>\n"
@@ -20,6 +20,16 @@ msgstr "Endereço encontrado."
msgid "CEP not found. Check the number or fill the address in by hand."
msgstr "CEP não encontrado. Confira o número ou preencha o endereço manualmente."
+msgid ""
+"CEP not found. This number would be in %1$s/%2$s, which has CEPs from %3$s "
+"to %4$s. Check the number."
+msgstr ""
+"CEP não encontrado. Esse número seria de %1$s/%2$s, que tem CEPs de %3$s a "
+"%4$s. Confira o número."
+
+msgid "CEP not found. This number would be in %1$s/%2$s. Check the number."
+msgstr "CEP não encontrado. Esse número seria de %1$s/%2$s. Confira o número."
+
msgid "Invalid CEP. Type all 8 digits."
msgstr "CEP inválido. Digite os 8 dígitos."