From 4a203aab57c69ea402939cf8fc423a0e5aaa1cab Mon Sep 17 00:00:00 2001 From: Hiroyuki Sato Date: Sat, 27 Jun 2015 03:11:20 +0900 Subject: Fix wrong order of issues when importing from github See API details at https://developer.github.com/v3/issues/. Refs #1791 --- lib/gitlab/github_import/importer.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/gitlab/github_import/importer.rb b/lib/gitlab/github_import/importer.rb index 23832b3233c..98039a76dcd 100644 --- a/lib/gitlab/github_import/importer.rb +++ b/lib/gitlab/github_import/importer.rb @@ -11,7 +11,9 @@ module Gitlab def execute #Issues && Comments - client.list_issues(project.import_source, state: :all).each do |issue| + client.list_issues(project.import_source, state: :all, + sort: :created, + direction: :asc).each do |issue| if issue.pull_request.nil? body = @formatter.author_line(issue.user.login, issue.body) -- cgit v1.2.3