Modified some FileSystem APIs as per the review documents.

This commit is contained in:
atanasovg
2014-04-25 12:04:07 +03:00
parent ce89af2643
commit cfaff493a6
3 changed files with 76 additions and 71 deletions

View File

@ -349,7 +349,8 @@ export class FileSystemAccess {
private getFileExtension(path: string): string {
var dotIndex = path.lastIndexOf(".");
if (dotIndex && dotIndex >= 0 && dotIndex < path.length) {
return path.substring(dotIndex);
// return the extension without the "." (like in iOS)
return path.substring(dotIndex + 1);
}
return undefined;