Initialized variables and code style
Owen Barton - July 11, 2007 - 01:16
| Project: | Views Argument API |
| Version: | 5.x-1.0 |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | needs review |
Description
There were 2 uninitialized variables that create warnings if you haven't saved the view manually before visiting the block configure page - this patch initializes them.
Also, the module was using tabs instead of double spaces, or a mixture (the Drupal coding standards is for double spaces only) - so I did some search and replaces too, to tidy this up (coder module would probably reveal some other issues).
Great module - I look forward to putting it through it's paces!
| Attachment | Size |
|---|---|
| views_argument_api-var-init.patch | 19.57 KB |

#1
Here is a better patch - I found a few more uninitialized arrays, and also fixed a few more minor coding standards issues
#2
#3
This includes 2 other fixes - views_argument_api_handler_default_form_value throwing errors because it was called without a value (on a block that had been saved without an update to enter the arg value) and also the array merge issue (see 156328).
#4
Grugnog,
Thank you for this. Sorry to trouble you, but some development had taken place on the module without a commit after you had generated this patch. Would you mind creating your patch against a newer version of this module?
#5
Morris, just want to be certain you tried applying this patch anyway. The way CVS works, you can usually apply a patch as long as the code you changed doesn't directly conflict with the code in the patch.