Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'apps/contacts/ajax/setproperty.php')
-rw-r--r--apps/contacts/ajax/setproperty.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/contacts/ajax/setproperty.php b/apps/contacts/ajax/setproperty.php
index f3b8e0c56b7..8b9bc4b3cfe 100644
--- a/apps/contacts/ajax/setproperty.php
+++ b/apps/contacts/ajax/setproperty.php
@@ -45,13 +45,13 @@ if( $addressbook === false || $addressbook['userid'] != OC_USER::getUser()){
exit();
}
+$vcard = OC_Contacts_Addressbook::parse($card['carddata']);
// Check if the card is valid
-if( !OC_Contacts_Addressbook::isValidVObject($card['carddata'])){
+if(is_null($vcard)){
echo json_encode( array( 'status' => 'error', 'data' => array( 'message' => $l10n->t('Unable to parse vCard!'))));
exit();
}
-$vcard = Sabre_VObject_Reader::read($card['carddata']);
$line = null;
for($i=0;$i<count($vcard->children);$i++){
if(md5($vcard->children[$i]->serialize()) == $checksum ){