function lazyloader_update_7001 in Image Lazyloader 7.2
Same name and namespace in other branches
- 7 lazyloader.install \lazyloader_update_7001()
Migrate settings.
File
- ./
lazyloader.install, line 46 - Lazyloader Install
Code
function lazyloader_update_7001() {
$settings = variable_get('lazyloader', array());
if (isset($settings['enabled'])) {
variable_set('lazyloader_enabled', $settings['enabled']);
}
if (isset($settings['distance'])) {
variable_set('lazyloader_distance', $settings['distance']);
}
if (isset($settings['placeholder'])) {
variable_set('lazyloader_placeholder', $settings['placeholder']);
}
if (isset($settings['loader_icon'])) {
variable_set('lazyloader_icon', $settings['loader_icon']);
}
if (isset($settings['exclude'])) {
variable_set('lazyloader_paths', $settings['exclude']);
}
variable_del('lazyloader');
}