Skip to content
Snippets Groups Projects
Commit e0110e94 authored by Peter Rotich's avatar Peter Rotich
Browse files

Remove unused index var - to make Jared happy (j/k)

parent 56178f82
No related branches found
No related tags found
No related merge requests found
......@@ -117,7 +117,7 @@ if(!$ticket){ //New tickets...
}
//Ticket created...save attachments if enabled.
if($cfg->allowEmailAttachments() && ($attachments=$parser->getAttachments())) {
foreach($attachments as $k=>$attachment) {
foreach($attachments as $attachment) {
if($attachment['filename'] && $ost->isFileTypeAllowed($attachment['filename']))
$ticket->saveAttachment(array('name' => $attachment['filename'], 'data' => $attachment['body']), $msgid, 'M');
}
......
......@@ -135,7 +135,7 @@ class FAQ {
if($ids) {
$topics = $this->getHelpTopicsIds();
foreach($ids as $k=>$id) {
foreach($ids as $id) {
if($topics && in_array($id,$topics)) continue;
$sql='INSERT IGNORE INTO '.FAQ_TOPIC_TABLE
.' SET faq_id='.db_input($this->getId())
......@@ -163,7 +163,7 @@ class FAQ {
//Delete removed attachments.
$keepers = $vars['files']?$vars['files']:array();
if(($attachments = $this->getAttachments())) {
foreach($attachments as $k=>$file) {
foreach($attachments as $file) {
if($file['id'] && !in_array($file['id'], $keepers))
$this->deleteAttachment($file['id']);
}
......
......@@ -1408,7 +1408,7 @@ class Ticket{
//Canned attachments...
if($vars['cannedattachments'] && is_array($vars['cannedattachments'])) {
foreach($vars['cannedattachments'] as $k =>$fileId)
foreach($vars['cannedattachments'] as $fileId)
if($fileId && $this->saveAttachment($fileId, $respId, 'R'))
$attachments[] = $fileId;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment