ternary operator
String id = request.getParameter("aaa")==null? "" : request.getParameter("aaa");
can be refactored to
String id = request.getParameter("aaa");
if(id==null) id ="";
which can be furthered reduce to
String id = Utility.isNull(request.getParameter("aaa"));
public String isNull(String input){
if(input==null) return "";
return input;
}
Error'd: Bridge for Sale
-
"Scammer offers to buy Google" is certainly a new twist on a very old New
York con. *Jan B.* explains "Scammers have found a new way to steal money,
scra...
4 days ago