Opened 8 years ago
Closed 8 years ago
#34339 closed defect (bug) (fixed)
Default option for site_icon
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 4.4 | Priority: | normal |
Severity: | normal | Version: | 4.3 |
Component: | Options, Meta APIs | Keywords: | has-patch commit |
Focuses: | Cc: |
Description
If Default Icon is not defined then insert default option.
Attachments (7)
Change History (16)
#2
@
8 years ago
- Keywords reporter-feedback added
Can you explain why this should be needed? update_blog_option
would result in an additional, unneeded database query just so that there's a 0
.
If you want a different default value, we could pass that as the second argument to get_option
.
Also, why is SELECT option_value FROM wp_options WHERE option_name = 'site_icon' LIMIT 1
unnecessary? I mean, somehow we need to get that option from the database…
#3
@
8 years ago
- Keywords has-patch needs-testing added; reporter-feedback removed
- Milestone changed from Awaiting Review to Future Release
This is valid. Same problem as #26876.
#4
@
8 years ago
- Keywords needs-testing removed
- Milestone changed from Future Release to 4.4
34339.2.patch adds little coding standards improvements.
Works great so far.
#5
follow-up:
↓ 6
@
8 years ago
- Type changed from enhancement to defect (bug)
- Version set to 4.3
Shouldn't site_icon
be added to populate_options()
?
#6
in reply to:
↑ 5
@
8 years ago
- Keywords needs-refresh added
Replying to ocean90:
Shouldn't
site_icon
be added topopulate_options()
?
D'oh, that makes more sense :)
@sebastian.pisula: Thanks for the updated patch! Note that we use 4.4.0 instead of 4.4 for docs. Also, you mixed up the indentation in your patch (spaces vs. tabs).
Ps. Trac doesn't send notifications for new attachments. I usually write something afterwards to notify people.
if option not exists then wordpress send request to mysql all the time:
in my opinion unnecessary query