Closed (fixed)
Project:
Entity API
Version:
7.x-1.x-dev
Component:
Code - misc
Priority:
Major
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
10 Apr 2011 at 20:26 UTC
Updated:
23 May 2011 at 19:31 UTC
Jump to comment: Most recent file
Comments
Comment #1
amitaibuI think it's the same as #1099812: Docs on how to prevent fatal error when using entity_exportable_schema_fields() from hook_update_N() -- and indeed the solution is not to use entity_exportable_schema_fields(), but to copy it.
Comment #2
drunken monkeyCopy it and replace the
ENTITY_CUSTOMconstant, now that I think about it.Even though the default value shouldn't matter while uninstalling, it still prevents a notice.
Comment #3
fagoIndeed, that's problem. I guess the helper becomes useless then :(
Comment #4
fagoComment #5
fagoPatch attached. Please review.
Note that I left the function there, so that modules making use of it right now don't suddenly break.
Comment #6
drunken monkeyLooks alright to me.
Comment #7
fagothanks, committed.
Comment #8
sunIf you don't want others to call this function, then rename it to a private function. That will not only make clear that no one should call it, but also prevent anyone from not updating potential calling code.
Powered by Dreditor.
Comment #9
fagoAs noted above:
>Note that I left the function there, so that modules making use of it right now don't suddenly break.
That way we prevent an update and dependency nightmare for user. So for now, I think it is best to stay with the name.
Comment #10
drunken monkeyI agree with Wolfgang, the function shouldn't be removed nor renamed, at least for now.
We could issue a PHP notice when the function is called, though, to bring it to the attention of developers, while leaving users (virtually) unharmed.