Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
There are multiple uses of deprecated DB-functions like db_select, db_insert, db_query violations.
Comment | File | Size | Author |
---|---|---|---|
#4 | 2759475-4.patch | 153.62 KB | rajeshwari10 |
| |||
#2 | 2759475-2.patch | 153.62 KB | rajeshwari10 |
Comments
Comment #2
rajeshwari10 CreditAttribution: rajeshwari10 as a volunteer and at Blisstering Solutions commentedDone changes!!
Comment #4
rajeshwari10 CreditAttribution: rajeshwari10 as a volunteer and at Blisstering Solutions commentedComment #5
TR CreditAttribution: TR commentedFor uc_fulfillment, I'd prefer not to make any changes. When Package and Shipment are converted to entities, direct queries of the database will not be needed - any changes to the db_ functions here will just disappear.
Also, with the OO code, I would prefer to inject the db connection if possible rather than use the static methods on Database. The static methods should be used in the procedural code only.
Note that although these functions are technically deprecated, they will not disappear until Drupal 9, which is probably 5 years away. So I'd rather take the time to do this correctly rather than rush to remove the current working code.