get last commit message and no crash when minimizing