From 5898456e6cd588afce8f300dcd0868696cd4097e Mon Sep 17 00:00:00 2001 From: Dillon Buchanan Date: Sun, 12 Jan 2014 01:18:15 -0500 Subject: [PATCH] Made it so you can't edit files that arn't text based --- CodeHub.Core/ViewModels/Source/SourceViewModel.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CodeHub.Core/ViewModels/Source/SourceViewModel.cs b/CodeHub.Core/ViewModels/Source/SourceViewModel.cs index bc7b4749..2879b698 100755 --- a/CodeHub.Core/ViewModels/Source/SourceViewModel.cs +++ b/CodeHub.Core/ViewModels/Source/SourceViewModel.cs @@ -51,7 +51,7 @@ protected override async Task Load(bool forceCacheInvalidation) public ICommand GoToEditCommand { - get { return new MvxCommand(() => ShowViewModel(new EditSourceViewModel.NavObject { Path = _path, Branch = Branch, Username = Username, Repository = Repository }), () => TrueBranch); } + get { return new MvxCommand(() => ShowViewModel(new EditSourceViewModel.NavObject { Path = _path, Branch = Branch, Username = Username, Repository = Repository }), () => ContentPath != null && TrueBranch); } } public void Init(NavObject navObject)