Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix submodule info loading #4

Merged
merged 2 commits into from
Jan 14, 2016
Merged

Commits on Jan 13, 2016

  1. Fix regression causing no submodule info

    This fixes regression introduced in ebd9fb2,
    that GetSubModules was always returning empty submodule info because
    c.submoduleCache != nil check was always true since parseCommitData was setting
    commit.submoduleCache = newObjectCache() so it was always not-nil.
    
    Now we initialize submoduleCache in first GetSubModules call, next call will
    return cached entries.
    nanoant committed Jan 13, 2016
    Configuration menu
    Copy the full SHA
    d78e7ee View commit details
    Browse the repository at this point in the history
  2. Do not fail in GetCommitsInfo with no .gitmodules

    This fixes GetCommitsInfo returning
    
     GetSubModule (/somemodule): object does not exist [id: , rel_path: .gitmodules]
    
    when /somemodule is a ref entry but no .gitmodules file is present. Instead
    failing we just check for IsErrNotExist and return empty submodule url.
    
    This also fixes HTTP 500 internal error in Gogs for case described above.
    nanoant committed Jan 13, 2016
    Configuration menu
    Copy the full SHA
    919a66d View commit details
    Browse the repository at this point in the history