Fix for possible nullpointer reported in issue-123
| | |
| | | */
|
| | | @Override
|
| | | protected boolean isActionAllowed(RepositoryModel repository, String action) {
|
| | | if (action.equals(gitReceivePack)) {
|
| | | // Push request
|
| | | if (!repository.isBare) {
|
| | | logger.warn("Gitblit does not allow pushes to repositories with a working copy");
|
| | | return false;
|
| | | if (!StringUtils.isEmpty(action)) {
|
| | | if (action.equals(gitReceivePack)) {
|
| | | // Push request
|
| | | if (!repository.isBare) {
|
| | | logger.warn("Gitblit does not allow pushes to repositories with a working copy");
|
| | | return false;
|
| | | }
|
| | | }
|
| | | }
|
| | | return true;
|