dropbox_client.install in Dropbox Client 7.4
File
dropbox_client.install
View source
<?php
function dropbox_client_requirements($phase) {
$requirements = array();
if ($phase == 'runtime') {
$requirements['dropbox_client_app_keys'] = array(
'title' => t('Dropbox app configuration'),
);
if (!variable_get('dropbox_client_key', FALSE) || !variable_get('dropbox_client_secret', FALSE)) {
$requirements['dropbox_client_app_keys']['severity'] = REQUIREMENT_ERROR;
$requirements['dropbox_client_app_keys']['value'] = t('Dropbox app configuration not OK. Please see the <a href="@url"> configuration page for more info</a>', array(
'@url' => url('admin/config/content/dropbox_client/settings'),
));
}
else {
$requirements['dropbox_client_app_keys']['severity'] = REQUIREMENT_OK;
$requirements['dropbox_client_app_keys']['value'] = t('Dropbox client configuration OK.');
}
}
return $requirements;
}
function dropbox_client_update_7001() {
drupal_set_message(t('It is required to add some new settings to the dropbox client module. Please make sure to reconfigure your dropbox settings at the <a href="@url">settings page.</a>', array(
'@url' => url('admin/config/content/dropbox_client/settings'),
)), 'warning');
}