mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-05-09 23:51:34 +08:00
commit
f798b39dfa
@ -352,6 +352,9 @@ public class Base64 {
|
|||||||
* @since 5.7.5
|
* @since 5.7.5
|
||||||
*/
|
*/
|
||||||
public static boolean isBase64(byte[] base64Bytes) {
|
public static boolean isBase64(byte[] base64Bytes) {
|
||||||
|
if (base64Bytes == null || base64Bytes.length < 3) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
boolean hasPadding = false;
|
boolean hasPadding = false;
|
||||||
for (byte base64Byte : base64Bytes) {
|
for (byte base64Byte : base64Bytes) {
|
||||||
if (hasPadding) {
|
if (hasPadding) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user