Opened 12 years ago

Closed 12 years ago

Last modified 12 years ago

#3406 closed patch (worksforme)

MythWeb Host Name (Singular / Plural)

Reported by: anonymous Owned by: xris
Priority: minor Milestone: unknown
Component: mythweb Version: unknown
Severity: medium Keywords:
Cc: Ticket locked: no

Description

In the weather display on MythWeb I am seeing an error when I have multiple backends (Master + Slave) that have the same weather area defined. The weather.php module looks at the number of backends with the same site, if more then one it states "Hosts", if only one it states "Host".

File in SVN: trunk / mythplugins / mythweb / modules / weather / tmpl / default / weather.php

Line of the code in question: 29

Code in question: tn('Host', 'Hosts', count($site->hosts)

Resulting Error: !NoTrans: Hosts!!: mythtv, mythtv-bedroom

I have attached a patch that fixes the error for me.

Attachments (1)

hosts-patch (492 bytes) - added by anonymous 12 years ago.

Download all attachments as: .zip

Change History (4)

Changed 12 years ago by anonymous

Attachment: hosts-patch added

comment:1 Changed 12 years ago by xris

Resolution: worksforme
Status: newclosed

Your patch doesn't take translations into account. Plus, this works fine for me; "Hosts" exists in all translation files.

comment:2 Changed 12 years ago by anonymous

Your comments got me digging further;

Turn out the issue is with release-0-20-fixes branch.

In "root / branches / release-0-20-fixes / mythplugins / mythweb / modules / _shared / lang" folder the *.lang files are out of date with the code in the release-0-20-fixes branch for MythWeb. The "Host" and "Hosts" lines are not in English.lang and hence the error message I was seeing. If I add them to the file the error goes away. Given this is already fixed in trunk branch I don't know if this deserves to be re-opened under release-0-20-fixes, I will leave it to your digression.

comment:3 Changed 12 years ago by xris

There is no tn(Host,Hosts) type call in -fixes.

Sounds like you have half of the files from -fixes and half from trunk.

Note: See TracTickets for help on using tickets.