Skip to content

Commit

Permalink
Remove usage of internal Nashorn methods (fixes #74)
Browse files Browse the repository at this point in the history
  • Loading branch information
Sten Roger Sandvik committed Sep 25, 2017
1 parent daf9580 commit 27b3b3a
Showing 1 changed file with 1 addition and 2 deletions.
Expand Up @@ -3,13 +3,12 @@
import java.util.Date;

import jdk.nashorn.api.scripting.ScriptObjectMirror;
import jdk.nashorn.internal.runtime.ScriptRuntime;

public final class NashornHelper
{
public static boolean isUndefined( final Object value )
{
return ( value == null ) || ( value == ScriptRuntime.UNDEFINED );
return ( value == null ) || ( value.getClass().getSimpleName().equalsIgnoreCase( "undefined" ) );
}

public static boolean isDateType( final Object value )
Expand Down

0 comments on commit 27b3b3a

Please sign in to comment.