private SoftwareModule getModuleAndThrowExceptionIfThatFails(final Long moduleId) { final SoftwareModule softwareModule = softwareModuleRepository.findOne(moduleId); if (softwareModule == null) { LOG.debug("no software module with ID {} exists", moduleId); throw new EntityNotFoundException("Software Module: " + moduleId); } return softwareModule; }