Merge branch 'cc-5709-airtime-analyzer-store-file-size-and-hash-in-db' into saas-store-file-size-and-hash-in-db

Conflicts:
	airtime_mvc/application/Bootstrap.php

airtime_mvc/application/modules/rest/controllers/MediaController.php
This commit is contained in:
drigato 2015-02-17 16:19:58 -05:00
commit c1086842d3
6 changed files with 54 additions and 4 deletions

View file

@ -0,0 +1,20 @@
<?php
/**
* Created by PhpStorm.
* User: sourcefabric
* Date: 17/02/15
*/
class FileDataHelper {
/**
* We want to throw out invalid data and process the upload successfully
* at all costs, so check the data and sanitize it if necessary
* @param array $data array containing new file metadata
*/
public static function sanitizeData(&$data) {
// If the track number isn't numeric, this will return 0
$data["track_number"] = intval($data["track_number"]);
}
}