implemented a license check