维护效能,看到代码无限头疼
维护功能,看到代码无限头疼Java codepublic Map getMenuAccessMap(long userId) {if (new Long(userId)
维护功能,看到代码无限头疼
Java codepublic Map getMenuAccessMap(long userId) { if (new Long(userId) == null || "".equals(userId)) { throw new NullObjectException("用户Id不能为空"); }
你们有什么想说的?
[解决办法]坑爹的代码
[解决办法]new Long(userId) == null这永远都不成立
"".equals(userId)判断long为空字符串,这哥们可真有想象力