Opened 2 years ago

Closed 2 years ago

Last modified 2 years ago

#2953 closed Bug (fixed)

MultiSites Plugin API: String typecast does not invoke magical __toString method for PHP < 5.2.0

Reported by: peterb Owned by: peterb
Priority: normal Milestone: 1.7.x - Piwik 1.7.1
Component: Core Keywords:
Cc: Sensitive: no

Description (last modified by peterb)

In PHP Version < 5.2.0, a String-typecast of an object does not invoke its magic toString methods and returns only the ID of the Object. Reported in http://forum.piwik.org/read.php?5,85638,85880#msg-85880. Piwik then fails with an Exception.

Change History (4)

comment:1 Changed 2 years ago by peterb (peterbo)

  • Owner set to peterb
  • Status changed from new to assigned

comment:2 Changed 2 years ago by peterb (peterbo)

  • Description modified (diff)

comment:3 Changed 2 years ago by peterb (peterbo)

  • Resolution set to fixed
  • Status changed from assigned to closed

(In [5867]) Fixes #2953, manually invoke object's toString()-Method instead of typecasting it.

comment:4 Changed 2 years ago by peterb (peterbo)

  • Milestone set to 1.7.x - Piwik 1.7.1
Note: See TracTickets for help on using tickets.