refactored increment method in lock mongoose plugin