[buddypress-trac] [BuddyPress Trac] #6977: Audit all DB fetch methods to return integers where appropriate
buddypress-trac
noreply at wordpress.org
Fri Apr 29 03:35:14 UTC 2016
#6977: Audit all DB fetch methods to return integers where appropriate
------------------------------------+-----------------------------
Reporter: r-a-y | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Future Release
Component: Component - Any/All | Version:
Severity: normal | Resolution:
Keywords: dev-feedback has-patch |
------------------------------------+-----------------------------
Comment (by DJPaul):
Wait, wait? I've just looked at this properly. Why the heck are we casting
strings to integers EVERYWHERE instead of just fixing the relevant
properties when we fetch stuff from the database? I think the work done so
far, while well-intentioned, is the wrong approach.
For an example, see the new patch I've put up for the
`BP_Activity_Activity` which typecasts integer properties after we fetch
results from the database cache (done it this way instead of before being
cached because otherwise we have to force a cache flush after upgrade, but
that's a trivial change to make if we wanted to do it that way.
--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/6977#comment:10>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac
More information about the buddypress-trac
mailing list