Fixed unforeseen NPE