瀏覽代碼

null check on getClassName

Nicolas Cannasse 19 年之前
父節點
當前提交
d1e376af6c
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      std/Type.hx

+ 2 - 0
std/Type.hx

@@ -93,6 +93,8 @@ class Type {
 		Returns the complete name of the class of an object
 	**/
 	public static function getClassName( c : Class ) : String {
+		if( c == null )
+			return null;
 		#if flash9
 			return untyped __global__["flash.utils.getQualifiedClassName"](c);
 		#else true