Completed
Pull Request — master (#24)
by Lars
12:05
created
src/Intraface/modules/contact/Controller/Show.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
 
33 33
     function renderHtml()
34 34
     {
35
-        $smarty = $this->template->create(dirname(__FILE__) . '/templates/show');
35
+        $smarty = $this->template->create(dirname(__FILE__).'/templates/show');
36 36
         return $smarty->render($this, array('persons' => $this->getContactPersons()));
37 37
     }
38 38
 
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
     {
41 41
         $this->document->addScript('contact/contact_edit.js');
42 42
 
43
-        $smarty = $this->template->create(dirname(__FILE__) . '/templates/edit');
43
+        $smarty = $this->template->create(dirname(__FILE__).'/templates/edit');
44 44
         return $smarty->render($this);
45 45
     }
46 46
 
@@ -215,7 +215,7 @@  discard block
 block discarded – undo
215 215
             if (!$email->save(
216 216
                 array(
217 217
                     'subject' => 'Loginoplysninger',
218
-                    'body' => $this->getKernel()->setting->get('intranet', 'contact.login_email_text') . "\n\n" . $this->getContact()->getLoginUrl() . "\n\nMed venlig hilsen\nEn venlig e-mail-robot\n" . $this->getKernel()->intranet->get('name'),
218
+                    'body' => $this->getKernel()->setting->get('intranet', 'contact.login_email_text')."\n\n".$this->getContact()->getLoginUrl()."\n\nMed venlig hilsen\nEn venlig e-mail-robot\n".$this->getKernel()->intranet->get('name'),
219 219
                     'contact_id' => $this->getContact()->get('id'),
220 220
                     'from_email' => $this->getKernel()->intranet->address->get('email'),
221 221
                     'from_name' => $this->getKernel()->intranet->get('name'),
@@ -271,14 +271,14 @@  discard block
 block discarded – undo
271 271
         // get back the vCard and print it
272 272
         $output = $vcard->fetch();
273 273
 
274
-        $filename = $contact->get('name') . '.vcf';
274
+        $filename = $contact->get('name').'.vcf';
275 275
 
276 276
         header('HTTP/1.1 200 OK');
277
-        header('Content-Length: ' . strlen($output));
277
+        header('Content-Length: '.strlen($output));
278 278
         //header("Content-Type: application/force-download");
279 279
         header('Content-Type: text/x-vCard; name='.$filename);
280
-        header('Content-Disposition: attachment; filename='. $filename);
281
-        header('Content-Description: VCard for ' . $contact->get('name'));
280
+        header('Content-Disposition: attachment; filename='.$filename);
281
+        header('Content-Description: VCard for '.$contact->get('name'));
282 282
         //header("Content-Transfer-Encoding: binary');
283 283
         header('Connection: close');
284 284
 
Please login to merge, or discard this patch.
src/Intraface/modules/contact/Controller/Memo.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -11,13 +11,13 @@
 block discarded – undo
11 11
 
12 12
     function renderHtml()
13 13
     {
14
-        $smarty = $this->template->create(dirname(__FILE__) . '/templates/memo');
14
+        $smarty = $this->template->create(dirname(__FILE__).'/templates/memo');
15 15
         return $smarty->render($this, array('reminder' => $this->getMemo()));
16 16
     }
17 17
 
18 18
     function renderHtmlEdit()
19 19
     {
20
-        $smarty = $this->template->create(dirname(__FILE__) . '/templates/memo-edit');
20
+        $smarty = $this->template->create(dirname(__FILE__).'/templates/memo-edit');
21 21
         return $smarty->render($this, array('reminder' => $this->getMemo()));
22 22
     }
23 23
 
Please login to merge, or discard this patch.
src/Intraface/modules/contact/Controller/Import.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@  discard block
 block discarded – undo
20 20
     {
21 21
         $data = array('data' => $this->session()->get('fileimport_data'));
22 22
 
23
-        $smarty = $this->template->create(dirname(__FILE__) . '/templates/import');
23
+        $smarty = $this->template->create(dirname(__FILE__).'/templates/import');
24 24
         return $smarty->render($this, $data);
25 25
     }
26 26
 
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
                 $string_appender->addKeywordsByString($_POST['keyword']);
49 49
                 $this->success++;
50 50
             } else {
51
-                $this->errors[$e]['line'] = $line+1; // line starts at 0
51
+                $this->errors[$e]['line'] = $line + 1; // line starts at 0
52 52
                 $this->errors[$e]['name'] = $contact['name'];
53 53
                 $this->errors[$e]['email'] = $contact['email'];
54 54
                 $this->errors[$e]['error'] = $contact_object->error;
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
         $data = $this->session()->set('fileimport_data', null);
60 60
 
61 61
         if (empty($this->errors)) {
62
-            return new k_SeeOther($this->url('../', array('flare' => $this->success . ' contacts imported successfully')));
62
+            return new k_SeeOther($this->url('../', array('flare' => $this->success.' contacts imported successfully')));
63 63
         }
64 64
 
65 65
         return $this->render();
Please login to merge, or discard this patch.
src/Intraface/modules/contact/Controller/Merge.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
         $contact = $this->context->getContact();
35 35
         $similar_contacts = $contact->getSimilarContacts();
36 36
 
37
-        $smarty = $this->template->create(dirname(__FILE__) . '/templates/merge');
37
+        $smarty = $this->template->create(dirname(__FILE__).'/templates/merge');
38 38
         return $smarty->render($this);
39 39
     }
40 40
 
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
      */
74 74
     function setNewContactId($old_contact_id, $new_contact_id)
75 75
     {
76
-        $this->db_sql->query('UPDATE contact_person SET contact_id = ' . $new_contact_id . ' WHERE contact_id = ' . $old_contact_id);
76
+        $this->db_sql->query('UPDATE contact_person SET contact_id = '.$new_contact_id.' WHERE contact_id = '.$old_contact_id);
77 77
         return true;
78 78
     }
79 79
 
Please login to merge, or discard this patch.
src/Intraface/Factory.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@  discard block
 block discarded – undo
22 22
     {
23 23
         $db = MDB2::singleton(DB_DSN, array('persistent' => true));
24 24
         if (PEAR::isError($db)) {
25
-            throw new Exception($db->getMessage() . $db->getUserInfo());
25
+            throw new Exception($db->getMessage().$db->getUserInfo());
26 26
         }
27 27
 
28 28
         $db->setFetchMode(MDB2_FETCHMODE_ASSOC);
@@ -80,7 +80,7 @@  discard block
 block discarded – undo
80 80
         //always check for errors. In this examples, error checking is omitted
81 81
         //to make the example concise.
82 82
         if (PEAR::isError($translation)) {
83
-            throw new Exception('Could not start Translation ' . $translation->getMessage());
83
+            throw new Exception('Could not start Translation '.$translation->getMessage());
84 84
         }
85 85
 
86 86
         // set the group of strings you want to fetch from
@@ -99,9 +99,9 @@  discard block
 block discarded – undo
99 99
         // %url% will be replaced with the targeted url
100 100
         //$this->translation->outputString = '%stringID% (%pageID_url%)'; //default: '%stringID%'
101 101
         $translation->outputString = '%stringID%';
102
-        $translation->url = '';           //same as default
103
-        $translation->emptyPrefix  = '';  //default: empty string
104
-        $translation->emptyPostfix = '';  //default: empty string
102
+        $translation->url = ''; //same as default
103
+        $translation->emptyPrefix  = ''; //default: empty string
104
+        $translation->emptyPostfix = ''; //default: empty string
105 105
         return $translation;
106 106
     }
107 107
 
Please login to merge, or discard this patch.
src/Intraface/XMLRPC/Server0200.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@
 block discarded – undo
70 70
 
71 71
         if (count($credentials) != 2) { // -4
72 72
             require_once 'XML/RPC2/Exception.php';
73
-            throw new XML_RPC2_FaultException('wrong argument count in $credentials - got ' . count($credentials) . ' arguments - need 2', -4);
73
+            throw new XML_RPC2_FaultException('wrong argument count in $credentials - got '.count($credentials).' arguments - need 2', -4);
74 74
         }
75 75
         if (empty($credentials['private_key'])) { // -5
76 76
             require_once 'XML/RPC2/Exception.php';
Please login to merge, or discard this patch.
src/Intraface/XMLRPC/Newsletter/Server.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
 
74 74
         if (!$this->subscriber->unsubscribe($email)) {
75 75
             require_once 'XML/RPC2/Exception.php';
76
-            throw new XML_RPC2_FaultException('you could not unsubscribe with ' .$email, -4);
76
+            throw new XML_RPC2_FaultException('you could not unsubscribe with '.$email, -4);
77 77
         }
78 78
 
79 79
         return true;
@@ -175,7 +175,7 @@  discard block
 block discarded – undo
175 175
     function getListIdFromOptinCode($credentials, $code)
176 176
     {
177 177
         $db = MDB2::singleton(DB_DSN);
178
-        $result = $db->query('SELECT list_id FROM newsletter_subscriber WHERE code = ' . $db->quote($code, 'text'));
178
+        $result = $db->query('SELECT list_id FROM newsletter_subscriber WHERE code = '.$db->quote($code, 'text'));
179 179
         if ($row = $result->fetchRow(MDB2_FETCHMODE_ASSOC)) {
180 180
             return $row['list_id'];
181 181
         }
@@ -193,7 +193,7 @@  discard block
 block discarded – undo
193 193
     {
194 194
         if (count($credentials) != 2) { // -4
195 195
             require_once 'XML/RPC2/Exception.php';
196
-            throw new XML_RPC2_FaultException('wrong argument count in $credentials - got ' . count($credentials) . ' arguments - need 2', -4);
196
+            throw new XML_RPC2_FaultException('wrong argument count in $credentials - got '.count($credentials).' arguments - need 2', -4);
197 197
         }
198 198
         if (empty($credentials['private_key'])) { // -5
199 199
             require_once 'XML/RPC2/Exception.php';
Please login to merge, or discard this patch.
src/Intraface/XMLRPC/Newsletter/Server0100.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -89,7 +89,7 @@  discard block
 block discarded – undo
89 89
 
90 90
         if (!$this->subscriber->unsubscribe($email, $comment)) {
91 91
             require_once 'XML/RPC2/Exception.php';
92
-            throw new XML_RPC2_FaultException('you could not unsubscribe ('. implode(', ', $this->subscriber->error->getMessage()).')', -4);
92
+            throw new XML_RPC2_FaultException('you could not unsubscribe ('.implode(', ', $this->subscriber->error->getMessage()).')', -4);
93 93
         }
94 94
 
95 95
         return $this->prepareResponseData(true);
@@ -208,7 +208,7 @@  discard block
 block discarded – undo
208 208
         $code = $this->processRequestData($code);
209 209
 
210 210
         $db = MDB2::singleton(DB_DSN);
211
-        $result = $db->query('SELECT list_id FROM newsletter_subscriber WHERE code = ' . $db->quote($code, 'text'));
211
+        $result = $db->query('SELECT list_id FROM newsletter_subscriber WHERE code = '.$db->quote($code, 'text'));
212 212
         if ($row = $result->fetchRow(MDB2_FETCHMODE_ASSOC)) {
213 213
             return $this->prepareResponseData($row['list_id']);
214 214
         }
Please login to merge, or discard this patch.
src/Intraface/XMLRPC/Controller/Server.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -86,7 +86,7 @@
 block discarded – undo
86 86
         }
87 87
 
88 88
         $options = array(
89
-            'prefix' => $this->prefix . '.',
89
+            'prefix' => $this->prefix.'.',
90 90
             'encoding' => $this->getEncoding(), // $this->encoding
91 91
             'backend' => $this->getBackend());
92 92
 
Please login to merge, or discard this patch.