A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/phan/phan/issues/386 below:

Support class @property · Issue #386 · phan/phan · GitHub

We are using Yii which uses a lot of magic, specifically around it's active records. We have a lot of models that look like this (most attributes removed for brevity):

/**
 * @property string                        $CompanyName
 * @property string                        $locale
 * @property KountaDateTimeZone            $timezone
 * @property Currency                      $currency
 * @property-read SiteEntity[]             $sites
 */
class MasterCompanyEntity extends KountaActiveRecord implements DuplicatableInterface

It looks like phan can't understand these, when used like this:

$this->company->timezone->getOffsetString()
PhanNonClassMethodCall Call to method getOffsetString on non-class type array

I don't know how its deciding that timezone is an array, changing the type in the @Property always returns the same error.

Is there any solution for this?


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4