Commit 747205cc8d6901045c5f7b4cc31bcb2782da4a57

Authored by Megan Watson
1 parent 384ef967

Fixed exception in ktapi.

Committed by: Megan Watson
Showing 1 changed file with 3 additions and 7 deletions
ktapi/KTAPIAcl.inc.php
... ... @@ -820,14 +820,10 @@ abstract class KTAPI_AllocationBase extends KTAPI_Dynamic
820 820  
821 821 break;
822 822 case 'KTAPI_Document':
823   - DocumentTransaction::createFromArray(array(
824   - 'folderid' => $objectId,
825   - 'comment' => $comment,
826   - 'transactionNS' => $namespace,
827   - 'userid' => $_SESSION['userID'],
828   - 'ip' => Session::getClientIP(),
829   - ));
  823 + $oDocumentTransaction = new DocumentTransaction($object, $comment, $namespace);
  824 + $res = $oDocumentTransaction->create();
830 825 break;
  826 +
831 827 default:
832 828 throw new Exception('Unexpected type: ' . $type);
833 829 }
... ...