PEAR is discontinued

This is a static archive preserving historical releases and metadata. No new packages or updates will be published. For updates to existing packages, or to publish new packages, please use Composer and Packagist.

Home » Internationalization » Translation2 » Bug #2890

getLang() notices if setLang() is not falled before

Details

Submitted2004-12-04 20:04 UTC
Fromtobias dot eberle at gmx dot de
Assignedquipo
StatusClosed
PackageTranslation2
PHP Version4.3.9
OSLinux
Roadmaps(Not assigned)

Comments

[2004-12-04 20:04 UTC] tobias dot eberle at gmx dot de

Description:
------------
If I call Translation2::getLang(id) without calling Translation2::setLang(id) before, I get a notice:
Notice: Undefined index: id in /usr/share/php/Translation2.php on line 274

Reproduce code:
---------------
$cTranslation2 = Translation2::factory(...);
//we dont call setLang() here
$cTranslation2->getLang(id)

Expected result:
----------------
no notice

Actual result:
--------------
Notice: Undefined index: id in /usr/share/php/Translation2.php on line 274