Skip to content

Commit

Permalink
Merge 37cc7c0 into bfae88e
Browse files Browse the repository at this point in the history
  • Loading branch information
crspeller committed Mar 17, 2017
2 parents bfae88e + 37cc7c0 commit 805667c
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 1,127 deletions.
4 changes: 1 addition & 3 deletions cmd/platform/channel.go
Expand Up @@ -120,16 +120,14 @@ func createChannelCmdF(cmd *cobra.Command, args []string) error {
return errors.New("Unable to find team: " + teamArg)
}

c := getMockContext()

channel := &model.Channel{
TeamId: team.Id,
Name: name,
DisplayName: displayname,
Header: header,
Purpose: purpose,
Type: channelType,
CreatorId: c.Session.UserId,
CreatorId: "",
}

if _, err := app.CreateChannel(channel, false); err != nil {
Expand Down
17 changes: 2 additions & 15 deletions cmd/platform/mattermost.go
Expand Up @@ -5,7 +5,6 @@ package main

import (
"errors"
"flag"
"fmt"
"os"

Expand Down Expand Up @@ -36,20 +35,8 @@ func main() {

rootCmd.AddCommand(serverCmd, versionCmd, userCmd, teamCmd, licenseCmd, importCmd, resetCmd, channelCmd, rolesCmd, testCmd, ldapCmd)

flag.Usage = func() {
rootCmd.Usage()
}
parseCmds()

if flagRunCmds {
CommandPrintErrorln("---------------------------------------------------------------------------------------------")
CommandPrintErrorln("DEPRECATED! All previous commands are now deprecated. Run: platform help to see the new ones.")
CommandPrintErrorln("---------------------------------------------------------------------------------------------")
doLegacyCommands()
} else {
if err := rootCmd.Execute(); err != nil {
os.Exit(1)
}
if err := rootCmd.Execute(); err != nil {
os.Exit(1)
}
}

Expand Down

0 comments on commit 805667c

Please sign in to comment.