git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [JGIT PATCH 1/2] Cleanup Transport.applyConfig to use setter methods more consistently
@ 2009-06-21  1:21 Shawn O. Pearce
  2009-06-21  1:21 ` [JGIT PATCH 2/2] Add support for remote.name.pushurl Shawn O. Pearce
  0 siblings, 1 reply; 4+ messages in thread
From: Shawn O. Pearce @ 2009-06-21  1:21 UTC (permalink / raw)
  To: Robin Rosenberg; +Cc: git

This just struck me as odd that we sometimes used a setter method,
and sometimes used direct assignment to the field.  Now we use the
setter method if it is available.  The fetch and push refspecs do
not have setters, so must still be done by direct field assignment.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
---
 .../src/org/spearce/jgit/transport/Transport.java  |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/org.spearce.jgit/src/org/spearce/jgit/transport/Transport.java b/org.spearce.jgit/src/org/spearce/jgit/transport/Transport.java
index 1068f50..c36ccdd 100644
--- a/org.spearce.jgit/src/org/spearce/jgit/transport/Transport.java
+++ b/org.spearce.jgit/src/org/spearce/jgit/transport/Transport.java
@@ -568,9 +568,9 @@ public void setRemoveDeletedRefs(final boolean remove) {
 	 */
 	public void applyConfig(final RemoteConfig cfg) {
 		setOptionUploadPack(cfg.getUploadPack());
-		fetch = cfg.getFetchRefSpecs();
+		setOptionReceivePack(cfg.getReceivePack());
 		setTagOpt(cfg.getTagOpt());
-		optionReceivePack = cfg.getReceivePack();
+		fetch = cfg.getFetchRefSpecs();
 		push = cfg.getPushRefSpecs();
 	}
 
-- 
1.6.3.2.416.g04d0

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-06-23 16:50 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-06-21  1:21 [JGIT PATCH 1/2] Cleanup Transport.applyConfig to use setter methods more consistently Shawn O. Pearce
2009-06-21  1:21 ` [JGIT PATCH 2/2] Add support for remote.name.pushurl Shawn O. Pearce
2009-06-21 17:30   ` Robin Rosenberg
2009-06-23 16:50     ` Shawn O. Pearce

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).