Rev 1116 | Rev 1130 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 1116 | Rev 1121 | ||
---|---|---|---|
Line 275... | Line 275... | ||
275 | * @param $to |
275 | * @param $to |
276 | * @return int|null |
276 | * @return int|null |
277 | */ |
277 | */ |
278 | public function distance($to) { |
278 | public function distance($to) { |
279 | if (!is_object($to)) $to = OIDplusObject::parse($to); |
279 | if (!is_object($to)) $to = OIDplusObject::parse($to); |
- | 280 | if (!$to) return null; |
|
280 | if (!($to instanceof $this)) return null; |
281 | if (!($to instanceof $this)) return null; |
281 | 282 | ||
282 | $a = $to->aid; |
283 | $a = $to->aid; |
283 | $b = $this->aid; |
284 | $b = $this->aid; |
284 | 285 |