Skip to content

Commit

Permalink
shortener setup fix
Browse files Browse the repository at this point in the history
  • Loading branch information
voitto committed Sep 6, 2009
1 parent baf18ce commit 6756a5f
Show file tree
Hide file tree
Showing 8 changed files with 12 additions and 7 deletions.
2 changes: 1 addition & 1 deletion app/omb/controllers/identities.php
Expand Up @@ -513,7 +513,7 @@ function app_installer_json( &$vars ) {
$result = false;
$result = curl_exec( $curl );
if ($result) {
$data = unserialize($result);
$data = mb_unserialize($result);
foreach($data as $appname=>$appdata) {
$remote_list[$appname] = $appname;
}
Expand Down
2 changes: 1 addition & 1 deletion app/omb/plugins/omb.php
Expand Up @@ -475,7 +475,7 @@ function set_identity_from_nick(&$request,&$route) {
$Revision->set_param( 'find_by', $where );
$Revision->find();
while ($r = $Revision->MoveNext()) {
$i = unserialize($r->data);
$i = mb_unserialize($r->data);
if (is_object($i) && $nick == $i->nickname)
$id = $i->id;
}
Expand Down
2 changes: 1 addition & 1 deletion app/omb/plugins/wp.php
Expand Up @@ -817,7 +817,7 @@ function get_option( $opt ) {
$Setting =& $db->model('Setting');
$s = $Setting->find_by(array('name'=>$opt,'profile_id'=>get_profile_id()));
if ($s) {
$un = @unserialize(base64_decode($s->value));
$un = mb_unserialize(base64_decode($s->value));
if (is_array($un))
return $un;
return $s->value;
Expand Down
2 changes: 1 addition & 1 deletion app/translate/controllers/translations.php
Expand Up @@ -113,7 +113,7 @@ function _index( &$vars ) {
$status = array();

while ($lang = $collection->MoveNext()) {
$txt = unserialize($lang->data);
$txt = mb_unserialize($lang->data);
$thiscount = 0;
foreach($txt as $phrase=>$trans) {
if (!empty($trans)) {
Expand Down
2 changes: 1 addition & 1 deletion app/translate/views/translations/_edit.html
Expand Up @@ -30,7 +30,7 @@
<p><b>spacebefore]</b> and <b>[spaceafter</b> indicate the presence of a space character before or after the string</p>
</td>
</tr>
<?php if (!empty($Member->data)) { $arrdata = unserialize($Member->data); } ?>
<?php if (!empty($Member->data)) { $arrdata = mb_unserialize($Member->data); } ?>
<?php foreach ($template_fields as $field) : ?>
<tr>
<td><input name="trans_<?php echo $field; ?>" value="<?php if (isset($arrdata[$field])) echo $arrdata[$field]; ?>"></td>
Expand Down
5 changes: 5 additions & 0 deletions db/library/dbscript/_functions.php
Expand Up @@ -3064,3 +3064,8 @@ function mu_url() {
return true;
return false;
}

function mb_unserialize($serial_str) {
$out = preg_replace('!s:(\d+):"(.*?)";!se', "'s:'.strlen('$2').':\"$2\";'", $serial_str );
return unserialize($out);
}
2 changes: 1 addition & 1 deletion db/library/remy-tweed/cron.php
Expand Up @@ -178,7 +178,7 @@
foreach ($env as $key=>$val) {
if (substr($key,0,13) == 'importtwitter' && $val == 1) {
$optname = 'conf_for_'.$key;
$options = unserialize(get_option($optname));
$options = get_option($optname);
if (!$options) {
$options = array();
$options['busy'] = 0;
Expand Down
2 changes: 1 addition & 1 deletion wp-content/language/lang_chooser.php
Expand Up @@ -18,7 +18,7 @@
$Translation =& $db->model('Translation');
$lang = $Translation->find_by('code',$language_selected);
if ($lang)
$txt = unserialize($lang->data);
$txt = mb_unserialize($lang->data);

}

Expand Down

0 comments on commit 6756a5f

Please sign in to comment.