Commit 7077b92f authored by shiyu's avatar shiyu

媒体工具类

parent 636bde12
package com.wwdz.ch.core.util; package com.wwdz.ch.core.util;
import com.xxdxxs.utils.StringUtils;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
...@@ -23,7 +24,15 @@ public class MediaUtil { ...@@ -23,7 +24,15 @@ public class MediaUtil {
* @return * @return
*/ */
public static String getImageByCutVedio(String vedioUrl) { public static String getImageByCutVedio(String vedioUrl) {
return vedioUrl + CUT_VEDIO_SUFFIX; if (StringUtils.isEmpty(vedioUrl)) {
return null;
}
String[] url = vedioUrl.split(";");
StringBuffer stringBuffer = new StringBuffer();
for (String singleUrl : url) {
stringBuffer.append(singleUrl + CUT_VEDIO_SUFFIX).append(";");
}
return stringBuffer.deleteCharAt(stringBuffer.length() -1).toString();
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment