]> wagnertech.de Git - timetracker.git/blobdiff - client_delete.php
Siwtched to using isPost() function
[timetracker.git] / client_delete.php
index 8d3f65ef0c9de4e8e994378f3a08a4d9a2b9aad3..e566455a86de0669633ae99d936bdb539eddc1d0 100644 (file)
@@ -48,7 +48,7 @@ $form->addInput(array('type'=>'combobox','name'=>'delete_client_entries',
 $form->addInput(array('type'=>'submit','name'=>'btn_delete','value'=>$i18n->getKey('label.delete')));
 $form->addInput(array('type'=>'submit','name'=>'btn_cancel','value'=>$i18n->getKey('button.cancel')));
 
-if ($request->getMethod() == 'POST') {
+if ($request->isPost()) {
   if(ttClientHelper::getClient($id)) {
     if ($request->getParameter('btn_delete')) {
       if (ttClientHelper::delete($id, $request->getParameter('delete_client_entries'))) {
@@ -64,7 +64,7 @@ if ($request->getMethod() == 'POST') {
     header('Location: clients.php');
     exit();
   }
-} // post
+} // POST
 
 $smarty->assign('client_to_delete', $client_to_delete);
 $smarty->assign('forms', array($form->getName()=>$form->toArray()));