Skip to content

Commit

Permalink
mime type fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelwechner committed Apr 16, 2013
1 parent 78f1496 commit 614daf7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Expand Up @@ -504,7 +504,7 @@ public String getMimeTypeBySuffix(String suffix) {
} else if (suffix.equals("mp4")) {
return "video/mp4";
} else if (suffix.equals("m4v")) {
return "video/mp4";
return "video/x-m4v";
} else if (suffix.equals("ogv")) {
return "video/ogg";
} else if (suffix.equals("webm")) {
Expand Down
Expand Up @@ -97,7 +97,7 @@ public View getView(String viewId) throws Exception {
View view = new View();

String range = getEnvironment().getRequest().getHeader("Range");
if (range != null) {
if (range != null) { // INFO: Also see http://stackoverflow.com/questions/12768812/video-streaming-to-ipad-does-not-work-with-tapestry5, http://balusc.blogspot.ch/2009/02/fileservlet-supporting-resume-and.html
if(!range.equals("bytes=0-")) {
log.warn("Specific range requested for node '" + getRepoPath()+ "': " + range);
String[] ranges = range.split("=")[1].split("-");
Expand Down Expand Up @@ -546,7 +546,7 @@ public String getMimeTypeBySuffix(String suffix) {
} else if (suffix.equals("mp4")) {
return "video/mp4";
} else if (suffix.equals("m4v")) {
return "video/mp4";
return "video/x-m4v";
} else if (suffix.equals("ogv")) {
return "video/ogg";
} else if (suffix.equals("webm")) {
Expand Down

0 comments on commit 614daf7

Please sign in to comment.